sir ,
Again not execute Query ,and not show any error
if you have possible please help with small source code.
Thanks
sir ,
Again not execute Query ,and not show any error
if you have possible please help with small source code.
Thanks
Here are some tips:
- Use [code][/code] tags around code. Your persistence in ignoring this politely requested courtesy to readers is wearing very thin with this reader.
- Using an sqlite command line tool connect to the same database and execute the query manually. If it doesn't work here then it certainly won't work from your code.
- Read the QSqlQuery and QSqlError docs.
- Do not ignore the return value from QSqlQuery::exec()
- If the QSqlQuery::exec() call fails then do something with the QSqlQuery::lastError() and you will be very much wiser.
If your database looks like the one you are defining here then the problem is that you have no table called City. Follow the advice above and you will know precisely inside a minute.
While you are at it, have a look at all the bits of advice you have received on this same program fragment: here, here, and here
"We can't solve problems by using the same kind of thinking we used when we created them." -- Einstein
If you are posting code then please use [code] [/code] tags around it - makes addressing the problem easier.
thanks
my query executed
Bookmarks