ohh i copied the database to the sqlite terminal and did a select on the shell mode, and it did not give anything implying that nothing got inserted. will try the %s thing. thanks.
Igor Tandetnik wrote: > > rishabh wrote: >> i put a cout on the insert query string generated by mprintf. >> it was actually putting the table name within quotes itself, so >> putting the extra quotes was not required. > > %Q surrounds the name with the wrong type of quotes. %Q uses single > quotes (as in 't-t'), as required in SQL for string literals. For names, > you should use double quotes (as in "t-t"): %Q won't help you with that, > use plain vanilla %s and put the quotes in yourself. > >> now the insert command is not giving any error, but the values did not >> actually get inserted :( > > How do you determine this? > > I suggest you prepare and post a small sample program that reproduces > your problem. > > Igor Tandetnik > > > > _______________________________________________ > sqlite-users mailing list > sqlite-users@sqlite.org > http://sqlite.org:8080/cgi-bin/mailman/listinfo/sqlite-users > > -- View this message in context: http://www.nabble.com/SQL-error%3A-near-%22-%22%3A-syntax-error-tp25397896p25399654.html Sent from the SQLite mailing list archive at Nabble.com. _______________________________________________ sqlite-users mailing list sqlite-users@sqlite.org http://sqlite.org:8080/cgi-bin/mailman/listinfo/sqlite-users