-
Notifications
You must be signed in to change notification settings - Fork 7
Providing SQL statements #16
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Conversation
28c96aa to
29381bf
Compare
e37bed3 to
9973d2d
Compare
Korablev77
left a comment
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Otherwise seems to be great!
035f77f to
01977e0
Compare
01977e0 to
f644742
Compare
| TEST_CASE("CREATE TABLE"); | ||
| rid_t create_table = conn.execute("CREATE TABLE IF NOT EXISTS testing_sql " | ||
| "(column1 UNSIGNED PRIMARY KEY, " | ||
| "column2 VARCHAR(50), " |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Add also test cases including collations, autoincrements, different spans etc so that cover all possible values of metadata.
f644742 to
903a0de
Compare
-- Added support for execute(), which executes the SQL statement contained in the sql-statement parameter. It is also possible to execute an expression by its id, obtained using the prepare() function. -- Added new structures ColumnMap, SqlInfo, Metadata and readers for them. -- Added tests to check and as an example of how to use the function.
-- Added support for prepare(), which prepares the SQL statement contained in the sql-statement parameter. With execute() you can execute the expression by its id, obtained with the prepare() function. -- Added tests to check and as an example of how to use the function.
ef66eb7 to
8b41889
Compare
|
Thank you for the patch! Unfortunately, I wrote a new patch based on yours, but covering all the flaws I described above, and added you as a co-author. That is why I'm closing this PR as a duplicate of #74. |
Added support for sql queries. Implemented methods:
Connection::execute()- equivalent of box.execute()Connection::prepare()- equivalent of box.prepare()Added new structures
ColumnMap,SqlInfo,Metadataand readers for them.Added tests for the methods above.