New posts
This commit is contained in:
@@ -0,0 +1,8 @@
|
||||
# sectioning: three prompts, same input, merged in plain Java
|
||||
call | system: You review Java code for performance only. Reply with on... | user: String q = "select * from users where id=" + id;
|
||||
call | system: You review Java code for readability only. Reply with on... | user: String q = "select * from users where id=" + id;
|
||||
call | system: You review Java code for security only. Reply with one s... | user: String q = "select * from users where id=" + id;
|
||||
calls: 3, most calls in flight at once: 3
|
||||
security: SQL is built by string concatenation, which allows injection.
|
||||
performance: select * pulls every column when one row is needed.
|
||||
readability: The query string should be a named constant.
|
||||
Reference in New Issue
Block a user