GDA Missing records in SQLite

Graham Menhennitt graham at
Thu Feb 21 06:31:46 EST 2008

Mark Johnson wrote:
> PostgreSQL gives a warning for '', but accepts it; it prefers \'.  MySql 
> takes the ''; I'm not sure about \'.  Obviously SQLite won't take the \'.
> However, the real problem is that it is not gnucash-gda code which is 
> doing the escaping of the single quote.  It is libgda, probably the 
> SQLite provider.  Therefore not under this project's control.
Guys, this isn't the right way to do it. When using SQL, you should
never have to worry about quoting because you shouldn't build SQL
statements like that. Use a prepared statement and bind the values to
numbered or named parameters in the SQL. All the relevant providers
allow it. GDA allows it. Now there may be bugs in GDA - I don't know.
But at least try to get it to work before worrying about workarounds
like this.


More information about the gnucash-devel mailing list