Jay Young Member Licensed User Longtime User Jun 1, 2015 #1 How do you use the UPDATE statement to Update two joined tables in SQLite, I have table1 that has 9 columns in it and i Join Table2 that has 1 column in it with a Select statement, I want to be able to UPDATE both tables at the same time. Hope this is clear Thanks for any help Jay
How do you use the UPDATE statement to Update two joined tables in SQLite, I have table1 that has 9 columns in it and i Join Table2 that has 1 column in it with a Select statement, I want to be able to UPDATE both tables at the same time. Hope this is clear Thanks for any help Jay
Jay Young Member Licensed User Longtime User Jun 1, 2015 #2 this is the code i have been working on, Query = "UPDATE inventory SET item = ?, instock = ?, ordamt = ?, Type = ?, container = ?, date = ?, flag = ? Where _id = " & edtDbIdUP Cursor1 = Main.SQL100.ExecQuery2(Query, Array As Object(edtItemUP, edtInStockUP, edtOrdAmtUP, edtTypeUP, edtContainerUP, edtDateUP, edtFlagUP)) Query2 = "UPDATE monday SET pars = ? WHERE _id = " & edtDbIdUP Cursor2 = Main.SQL100.ExecQuery2(Query2, Array As Object(edtParsUP)) Upvote 0
this is the code i have been working on, Query = "UPDATE inventory SET item = ?, instock = ?, ordamt = ?, Type = ?, container = ?, date = ?, flag = ? Where _id = " & edtDbIdUP Cursor1 = Main.SQL100.ExecQuery2(Query, Array As Object(edtItemUP, edtInStockUP, edtOrdAmtUP, edtTypeUP, edtContainerUP, edtDateUP, edtFlagUP)) Query2 = "UPDATE monday SET pars = ? WHERE _id = " & edtDbIdUP Cursor2 = Main.SQL100.ExecQuery2(Query2, Array As Object(edtParsUP))
Erel B4X founder Staff member Licensed User Longtime User Jun 2, 2015 #3 You should use ExecNonQuery2 for an UPDATE command. Upvote 0