I am trying to use a SQLite UPDATE query and not sure of the proper syntax. I have tried a few differnt way but none works quite right. The issue is trying to include the single quote marks for the update query. I have 1 line edit and one combobox widget that contain the data for part of the string. Here is my last try:
Qt Code:
  1. Sqlstring=("UPDATE address set LName= '%1' WHERE id= %2")
  2. .arg(ui->txtLName->text()).arg(ui->cmbName->itemData(Index).toString());
To copy to clipboard, switch view to plain text mode 
I get the error messeage:
request for member 'arg' in (UPDATE rider set LName= \'%1'\ WHERE id= %2) which is of non class type const char [24].

What would be the best method to create the correct string keeping in mind that the ui->txtLName->text() needs to be enclosed ina single quotation mark?

Thanks a bunch!