SQLite

View Ticket
Login
Ticket Hash: d87336c81c7d0873f1cc53225271062372de1856
Title: Debug assertion sqlite3TableColumnAffinity: Assertion `iCol<pTab->nCol' failed.
Status: Fixed Type: Code_Defect
Severity: Important Priority: High
Subsystem: Unknown Resolution: Fixed
Last Modified: 2019-12-25 23:54:39
Version Found In: 3.30.0
User Comments:
mrigger added on 2019-12-25 00:39:04: (text/x-fossil-wiki)
Consider the following test case:

<pre>
CREATE VIRTUAL TABLE t0 USING rtree(c0, c1, c2);
SELECT * FROM t0 WHERE ((0, 0) IN (SELECT COUNT(*), LAG(5) OVER(PARTITION BY 0) FROM t0), 0) <= (t0.c1, 0); -- sqlite3.c:98053: sqlite3TableColumnAffinity: Assertion `iCol<pTab->nCol' failed.
</pre>

When compiling with -DSQLITE_DEBUG, the SELECT triggers an assertion error.