using UPDATE function in SQLite
Posted: Sun Jan 18, 2015 3:38 pm
Hi there!
This is my script, wich contained in Button controller and works when clicking the button:
on mouseUp
put "UPDATE Persons SET (Amplua='Rider',Name='Samuel',Lastname='Jackson',Origin='USA') WHERE Number='2'" into tSQL
revExecuteSQL DatabaseID, tSQL
--DatabaseID at this moment contains an actual database id, it's defined before!
revCloseDatabase DatabaseID
end mouseUp
I want to modify the cells in table of database. Table named "Persons". Field "Number" in every row contains number of person. Then i've got several fields like "Amplua" (person is rider, official or simple. it's like a status of person), "Name", "LastName" etc. Using WHERE clause, i set the destination (the row) where i want to update cells
but this structure doesn't work
((( what am i supposed to do?
This is my script, wich contained in Button controller and works when clicking the button:
on mouseUp
put "UPDATE Persons SET (Amplua='Rider',Name='Samuel',Lastname='Jackson',Origin='USA') WHERE Number='2'" into tSQL
revExecuteSQL DatabaseID, tSQL
--DatabaseID at this moment contains an actual database id, it's defined before!
revCloseDatabase DatabaseID
end mouseUp
I want to modify the cells in table of database. Table named "Persons". Field "Number" in every row contains number of person. Then i've got several fields like "Amplua" (person is rider, official or simple. it's like a status of person), "Name", "LastName" etc. Using WHERE clause, i set the destination (the row) where i want to update cells
but this structure doesn't work
