raise error for old sqlite versions when "INSERT INTO ... DEFAULT VALUES" is required
Issue #909
resolved
Using a secondaryjoin
condition on a relation triggers the use of the INSERT INTO ... DEFAULT VALUES
construct. This syntax is not available with SQLite 3.2.8 (the default on Ubuntu Dapper). Works fine against SQLite 3.4.2.
Comments (6)
-
Account Deleted -
I emailed D. Richard Hipp:
First appearance seems to be version 3.3.8. 2006-10-09.
-
- changed milestone to 0.5.0
Addressed in c622a86286573f2029e93923c2d5a98379fb794b. Now raises an exception so it's purposeful that empty inserts on versions prior to 3.3.8 are not supported.
I'm not sure whether we should close this or not. A workaround is quite flakey.
-
Account Deleted I'm the original reporter, and FWIW I'd be perfectly happy with your current solution.
-
repo owner - changed status to resolved
- changed title to raise error for old sqlite versions when "INSERT INTO ... DEFAULT VALUES" is required
this seems to be fixed, so closing
-
repo owner - removed milestone
Removing milestone: 0.5.0 (automated comment)
- Log in to comment
jek on IRC noted that single-column auto-increment tables are problematic on older versions of SQLite. Adding a dummy column fixed it.
Another solution is to explicitly insert a
NULL
for auto-increment columns:INSERT INTO ... VALUES (NULL)
. Works for me on 3.2.8 and 3.4.2.