From 3e7cc47af59d0f55fb827008b66b97ca432f91d4 Mon Sep 17 00:00:00 2001 From: scho4077 Date: Tue, 22 Sep 2015 21:57:52 -0500 Subject: [PATCH] Update Parserv2.cpp --- Parserv2.cpp | 14 +++----------- 1 file changed, 3 insertions(+), 11 deletions(-) diff --git a/Parserv2.cpp b/Parserv2.cpp index 427bbdb..4d4b742 100755 --- a/Parserv2.cpp +++ b/Parserv2.cpp @@ -171,22 +171,14 @@ vector deleteCMD(vector input){ cout << "\nPassing the following arguments to dbEngine: " << endl; cout << "command :" << input[0] << endl; - cout << "relation: " << input[1] << endl; + cout << "relation: " << input[2] << endl; for (int i = 0; i < input.size(); ++i) { cout << input[i] << "\n"; } } int main () { - string ss = "INSERT INTO animals VALUES FROM ( Joe , cat , 4 ) ;"; - string ss2 = "SHOW Dogs ;"; - string ss3 = "EXIT ; "; + string ss = "DELETE FROM animals WHERE (age == 12);"; - vector listOfTokens = tokenize(ss); - vector listOfTokens2 = tokenize(ss2); - vector listOfTokens3 = tokenize(ss3); - - par_line(listOfTokens); - par_line(listOfTokens2); - par_line(listOfTokens3); + vector listOfTokens = tokenize(s); }