Error while inserting rows into table with schema containing reserved words, e.g. table name == "table" or field name "from". Solution: escape identifiers in any place where necessary. Reproducible: Always Steps to Reproduce: 1. Create table such as "CREATE TABLE "TABLE" ("FROM" INTEGER) 2. Go to the data view and try to insert one record Actual Results: "Record inserting failed" In fact records get inserted but retrieving autoincremented values fails.
Created attachment 99722 [details] Test file that fails Try to insert records into "table" and "index" tables.
Git commit 69b8f18d4b1102fed1d06de07f6d1c953e00e617 by Jaroslaw Staniek. Committed on 27/06/2016 at 12:20. Pushed by staniek into branch 'calligra/2.9'. CalligraDB: Connection::lastInsertedAutoIncValue: escape <table> and <name> in "SELECT <table>.<name> FROM <table>" M +2 -1 libs/db/connection.cpp http://commits.kde.org/calligra/69b8f18d4b1102fed1d06de07f6d1c953e00e617
Git commit 729e2937e426bb9b715f0152aed66b5b11d2676a by Jaroslaw Staniek. Committed on 03/07/2016 at 00:12. Pushed by staniek into branch 'escape-sequences-staniek'. KDbConnection::lastInsertedAutoIncValue: escape <table> and <name> in "SELECT <table>.<name> FROM <table>" >From calligra.git 69b8f18d4b1102fe M +3 -2 src/KDbConnection.cpp http://commits.kde.org/kdb/729e2937e426bb9b715f0152aed66b5b11d2676a
Git commit c7111e0cf2335ac24bccd249284cfd1116bf2a1b by Jaroslaw Staniek. Committed on 18/07/2016 at 07:57. Pushed by staniek into branch 'master'. KDbConnection::lastInsertedAutoIncValue: escape <table> and <name> in "SELECT <table>.<name> FROM <table>" >From calligra.git 69b8f18d4b1102fe M +3 -2 src/KDbConnection.cpp http://commits.kde.org/kdb/c7111e0cf2335ac24bccd249284cfd1116bf2a1b