KMatle Expert Licensed User Longtime User Nov 6, 2017 #1 In a table I've got 2 columns with a foreign key and for a test I tried to change one to a not valid value. The result (as expected) Code: java.sql.SQLException: [SQLITE_CONSTRAINT] Abort due to constraint violation (foreign key constraint failed) ..... (nothing to see here) The exception doesn't tell which column is causing it. Does anyone know how to get it? (I searched the www but did not find a solution)
In a table I've got 2 columns with a foreign key and for a test I tried to change one to a not valid value. The result (as expected) Code: java.sql.SQLException: [SQLITE_CONSTRAINT] Abort due to constraint violation (foreign key constraint failed) ..... (nothing to see here) The exception doesn't tell which column is causing it. Does anyone know how to get it? (I searched the www but did not find a solution)
OliverA Expert Licensed User Longtime User Nov 6, 2017 #2 You may be out of luck, since all examples given in SQLite's documentation on foreign key constraints (https://sqlite.org/foreignkeys.html) show just the "foreign key constraint failed" message without specifying what exactly caused it, what tables/columns are involved. Upvote 0
You may be out of luck, since all examples given in SQLite's documentation on foreign key constraints (https://sqlite.org/foreignkeys.html) show just the "foreign key constraint failed" message without specifying what exactly caused it, what tables/columns are involved.
KMatle Expert Licensed User Longtime User Nov 6, 2017 #3 OliverA said: without specifying what exactly caused it Click to expand... Thought so :-( Then I have to check it by selecting each key. Thank's anyway. Upvote 0
OliverA said: without specifying what exactly caused it Click to expand... Thought so :-( Then I have to check it by selecting each key. Thank's anyway.