SQLite 3.53 patches stale expression index bug but only fixes rows on write
SQLite 3.53.0, released in April 2026, introduced a self-healing mechanism to address a long-standing issue where expression indexes could return wrong query results without any error or warning. The problem occurs when a custom SQL function's output changes after an index is built, causing stored index entries to no longer match what the expression would compute today. A developer reproduced the flaw by registering a scalar function, building an index, then reopening the database with a modified version of the function — resulting in two different rows returned for the same query depending on whether the index or a full scan was used. On SQLite versions before 3.53, writing to affected rows triggered an SQLITE_CORRUPT error even though the underlying data was intact. The new self-healing fix in 3.53 repairs index entries only for rows that are written to, meaning stale entries for unmodified rows can still serve incorrect read results.
This is an AI-generated summary. ShortSingh links to the original source for the complete article.
Discussion (0)
Log in to join the discussion and vote.
Log in