I am trying to do a simple SQLite query from inside and Air application:
var sqls:SQLStatement = new SQLStatement(); sqls.sqlConnection = sqlc; sqls.text = "UPDATE videos SET thumb = 'ram's' where id = 2"; sqls.execute();
I need to add ' same as ram's
SQLError: 'Error #3115: SQL Error.', details:'near 's': syntax error', operation:'execute', detailID:'2003'
I'm using "addslashes()" but not working
Not sure why it does not work. Please help me.
Your code is truncated or you have some issues with syntax. I suspect the former.
The syntax for the update is incorrect, you can use the update statement as
sqls.text = "UPDATE videos SET thumb = 'ram' + '''s' where id = 2";
Let me know if this worked.