Mark Johnson wrote:

By examining which transactions, accounts, and splits were missing from SQLite (as compared to MySQL), I was able to determine that anything which had a single quote in a string (description, name, & memo fields) failed to be inserted into SQLite. This is a one-to-one correspondence. i.e. anything that had a single quote failed. These were the only records missing as compared to MySql.

At the moment, I am guessing that the SQLite provider does not properly escape such strings passed to it. If so, the SQL INSERT statements would be illegal and fail. (I've built just such a bug myself once using MySql.)

More study of the SQLite provider is required. I did not find any existing bug reports regarding single quotes and the SQLite provider. If I can confirm my guess, I'll file the bug report.

This sounds more like a symptom of not using prepared statements in sqlite. This could be a GDA problem, or it could be sqlite not supporting prepared statements.

What is more worrying is that rows are being dropped and no error is being thrown. That looks to me like a more serious bug at this point, it means that strange data corruption errors are likely and the end user will never know.

Regards,
Graham
--

Attachment: smime.p7s
Description: S/MIME Cryptographic Signature

_______________________________________________
gnucash-devel mailing list
[email protected]
https://lists.gnucash.org/mailman/listinfo/gnucash-devel

Reply via email to