another ugly basic implementation
This commit is contained in:
5
main.cpp
5
main.cpp
@@ -16,7 +16,8 @@ int main(int argc, char *argv[]) {
|
||||
"insert into a (i, s) values(1, 'one')",
|
||||
"insert into a (i, s) values(2, 'two')",
|
||||
"insert into a (i, s) values(3, 'two')",
|
||||
"select i, s from a where i > 0"
|
||||
"insert into a (i, s) values(4, 'four')",
|
||||
"select i, s from a where i > 2"
|
||||
// "update a set s = 'three' where i = 3"
|
||||
// "delete from a where i = 3"
|
||||
// "select i, s from a where i > 0"
|
||||
@@ -25,7 +26,7 @@ int main(int argc, char *argv[]) {
|
||||
|
||||
for(auto command : sql_commands) {
|
||||
auto node = parser.parse(command);
|
||||
executor.execute(*node.get());
|
||||
executor.execute(*node);
|
||||
}
|
||||
|
||||
return 0;
|
||||
|
||||
Reference in New Issue
Block a user