master
Fix a 32-bit integer overflow in sqlite3changegroup_change_blob() that could lead to a buffer overwrite.
Minor patch to test/json/json-speed-check.sh. That script is not maintained, but this fix at least gets it working for now.
Make test_wholenumber.c into a loadable extension and move it to ext/misc/wholenumber.c.
Remove unnecessary "www." prefixes on domain names in URLs.
Faster :memory: database COMMITs. Ticket #1790. (CVS 3178)
Fix an error in new test script test/aggfault.test.
Disqualify the count-of-view optimization if the view is really a correlated subquery. [forum:/info/2026-07-18T10:23:43Z|Forum post 2026-07-18T10:23:43Z].
Do not allow the number of terms in an ORDER BY or GROUP BY clause to exceed the maximum number of columns in a table.
Rework the column-cache mechanism to be more robust (and more correct). The column-alias cache is currently disabled, (CVS 6538)
In Tcl, always use eq/ne for comparing strings, not ==/!=
Do not allow internal-use-only functions to be used in CHECK constraints that are added as part of ALTER TABLE ADD COLUMN.
Ensure that values generated by DEFAULT clauses that specify real numbers that can be expressed as 64-bit integers (e.g. -1234.0) are not silently converted to integers.
Approximately 100 typo corrections spanning the whole tree, submitted via [forum:0db9827f0464bc33|forum post 0db9827f0464bc33] and individually audited and verified. Affects only code comments, innocuous test strings, error message text in tool (not library) code, and configure-level help text.
Fix a compilation issue in the "userauth" extension. Also fix a few test script errors that occur with SQLITE_USER_AUTHENTICATION=1 builds.
Add tests for ALTER TABLE authorization callbacks and other things.
Fix some problems with DROP CONSTRAINT and DROP NOT NULL on generated columns.
Fix comment typos. Add test cases.
Allow "ALTER TABLE ... DROP CONSTRAINT" to drop foreign key constraints.
Change things so that SQLITE_OMIT_VIRTUALTABLE implies SQLITE_OMIT_ALTER_TABLE.
Ensure that all records are updated by setting the OPFLAG_SAVEPOSITION flag when updating records as part of ALTER TABLE DROP COLUMN.
Fix broken requirement marks.
Merge latest trunk changes into this branch.
Fix various issues with the changes on this branch. Add test cases for the same.
Enhance tester.tcl so that when "--malloctrace=1" is specified, the test generates self-contained Tcl scripts that present GUIs instead of *.sql files that require a separate program to interpret.
Update some OOM tests of the ALTER TABLE command to account for an error message which may be returned if opening the temp db fails.
Test module altermalloc3.test requires DQS_DDL to be turned on.
Fix a test case broken by the previous check-in.
Fix an obscure issue with ALTER TABLE RENAME that comes up with triggers that have UPDATE statements that contain errors. [forum:/forumpost/ff3840145a|Forum post ff3840145a].
When attempting to optimize "expr AND false" to "false" and "expr IN ()" to "false", take care not to delete aggregate functions in the "expr" as doing so can change the meaning of the query. See [forum:/forumpost/f4878de3e7dd4764|forum thread f4878de3e7].
Fix a problem with ALTER TABLE DROP COLUMN commands where the column being dropped is the rightmost in table and is immediately preceded by a comment containing a "," character.
Experimental change to allow triggers in the temp schema to use fully qualified table names in INSERT/UPDATE/DELETE statements.
Cap constraint values on constraints to the amatch virtual table so that they fit into a 32-bit signed integer. [bugs:/info/2026-08-02T13:01:25Z|Bug 2026-08-02T13:01:25Z]
Fix an assert that can go bad if STAT4 content is corrupt. This is a follow-up to the previous check-in.
Handle constraints like "a=$var" where the value bound to $var is -1, 0 or 1 in the same way as a literal -1, 0, 1. This might cause excessive reprepares.
Remove support for STAT3. The sqlite_stat3 tables are ignored, if they exist. STAT4 continues to work as it always has, and as it is a superset of STAT3 is the recommended replacement.
Revise tests cases to align with the new EXPLAIN QUERY PLAN output.
Minor STAT4 test case change due to the ANALYZE enhancement of [eb59c46a5aed69bc|check-in eb59c46a5aed69bc].
When reading sqlite_stat4 data during query planning, be sure to expand zeroblobs prior to running comparisons. Fix for the issue identified by [forum:/forumpost/5275207102|forum post 5275207102].
Changes to test/analyzeG.test to conform to the new EXPLAIN QUERY PLAN syntax.
On x64 hardware, round-trip uint64_t→double→uint64_t conversions fail for values greater than UINT64_MAX-2047. This caused the SQLite text-to-float converter routine to give incorrect results for values between '1.8446744073709550592eNNN' and '1.8446744073709551609eNNN' for any exponent NNN. This problem was introduced by check-in [761d8fd18b0ee868] and first appeared in version 3.47.0 and was reported by [forum:/forumpost/569a7209179a7f5e|forum post 569a7209179a7f5e]. Fixed by this check-in.
Improved rounding of floating-point conversions in some corner cases.
Add new test file test/atomic.test.
If an SQLITE_IOERR error is encountered as part of an atomic commit on an F2FS file-system, retry the commit in legacy journal mode.
Extend the refactoring into extensions. Clean up stray newlines.
Ensure that the database encoding cannot be changed while there are statements running. And that the connection is left in a valid state after an obscure OOM within sqlite3_deserialize().
All temp.sqlite_master to be used as an alias for sqlite_temp_master.
In the documentation emphasize that the use of shared cache is discouraged. Fix test cases so that they all work with shared cache disabled.
Fix a bug in the check-in [bbd69ce274620008] causing that bug-fix check-in to fail to completely fix the original bug. This fix is in response to the follow-up report at [bugs:/info/2026-07-24T02:52:08Z|Bug 2026-07-24T02:52:08Z].
Enhance the xfer-optimization to verify access to the source table using the authorizer, if an authorizer is registered. [bugs:/info/2026-05-21T03:31:22Z|Bug 2026-05-21T03:31:22Z].
Do not run test file autoanalyze1.test if OMIT_VIRTUALTABLE is defined.
Add the ability for Bloom filters to work on text values, as long as the collating sequence is BINARY.
Do not use an automatic index on an outer loop that only runs once.
Avoid creating an automatic index on a column that is known to be not very selective.
Fix the LEFT JOIN strength reduction for IN operators in the WHERE clause. Further simplifications and refinement of the algorithm.
Demostrate a prototype sqlite3_autovacuum_pages() interface.
Add retry logic for AV defense to winOpen. Also, refactor test suite to allow the key Tcl file operations (e.g. copy and delete) to be retried.
Fix test cases impacted by the use of ~/.sqliterc
Get rid of "-encoding binary" across all test cases, as that is no longer supported in Tcl9. Use "-translation binary" instead.
Fix a segfault that could occur if a non-empty in-memory database was the destination of a backup operation from a database with a smaller page size.
Test app/script patches from Jan Nijtmans for cygwin. Add/replace many more sentinel arguments for TCL variadic functions which specifically need a NULL trailing argument. With this, 'make test' on cygwin runs to completion for me, with 134 of 329227 tests failing. MSC build fails the same 13 tests which fail for me in trunk.
Many test cases fixed to work with encryption.
Add test case to backup5.test to verify that detaching the destination database from its handle is handled correctly.
Many spelling fixes in comments. No changes to code.
Fix the backup_malloc.test script so that it works on Windows.
Performance improvement in the substr() and length() SQL functions. Caution: The new code may give different results for malformed UTF8. I do not consider that to be a problem by the GI/GO principle.
Test case changes so that they work with both Tcl8.6 and Tcl8.7.
Fix some integer overflow warnings in the base64 and base85 extensions.
More ==/!= => eq/ne fixes
Test cases for sqlite3_vtab_in() and sqlite3_vtab_distinct().
Allow queries that use "GROUP BY e1 ORDER BY e2" where e1 and e2 are identical aprt from ASC/DESC sort-orders to be optimized using a single index. Also allow virtual tables to optimize DISTINCT in cases where the result-set of a query does not exactly match the ORDER BY clause.
Add string_agg(X,Y) as an alias for group_concat(X,Y), for compatibility with SQLServer and PG.
Omit explain_i calls from TCL test scripts.
Do not attempt the OR-optimization on conjuncts that contain COLLATE operators because (1) such cases are rare and (2) they are tricky to get right and are thus prone to bugs and hard to test. [bugs:/forumpost/329521b269|Bugs report 329521b269] is one such bug that goes back about 20 years and thus demonstrates both points of the previous sentence.
Ensure the sqlite3_index_info.colUsed mask always includes the PK fields of WITHOUT ROWID vtabs in cases where they may be used.
Add better test case for the issue with dropping RETURNING triggers when the schema is reset while preparing a statement.
Relax the restrictions on reordering tables in vtab queries that occur to the right of a LEFT or CROSS JOIN but are not actually the RHS of said join.
Add test case to between.test.
Disable the bigfile tests on Macs.
Fix test issues for Windows portability.
Change the fake_big_file test command so that it fails for files larger than 2MB on Windows, as we have observed that Window10 will sometimes bluescreen when operating on very large sparse files.
Fix an assert() that could fail when reading a blob or text value larger than 1GiB from the database (requires a non-default build configuration). This is an assert() fix only, production builds were functioning correctly.
Avoid running bigsort.test with SQLITE_DEBUG builds. The assert() statements added in [7c96a56] make it too slow.
Update error message text for standard error codes to better describe the latest usage of those error codes. Modify sqlite3_open_v2() so that it does return a valid sqlite3 object in the event of SQLITE_MISUSE due to bad open flags, so that sqlite3_errmsg() does not report "out of memory" in that case.
Fix the bind2.test test script so that it works even if SQLITE_ENABLE_PREUPDATE_HOOK is not defined. Fix for test-case breakage from check-in [c006515ae6faff65].
Check-in (6514) did not completely remove the obsolete test, resulting in a segfault. This check-in finishes the job. Ticket #3802. (CVS 6516)
Increase test coverage of bitvec.c slightly. Fix the line length on a comment in bitvec.c. (CVS 6432)
Fix an out-of-order test number in blob.test. Cosmetic change. No changes to code. Ticket #3830. (CVS 6564)
New test cases for Bloom filter use on text keys as long as the collating sequence is binary.
Many of the boundary tests depend on a working 64-bit implementation of TCL, so skip them if this is not available. (CVS 6099)
Update the boundary3.tcl script so that it can be run with tcl 8.5 or 8.6 to regenerate boundary3.test.
Improvements to ORDER BY handling in the NGQP. Fix an "exit" mistakenly left in a test script during the previous check-in.
Various fixes so that "make test" works with OMIT_FOREIGN_KEY, OMIT_TRIGGER and OMIT_ALTER_TABLE.
Modify the btree02.test module so that it does not depend on whether TCL interprets a value as a string or as an integer.
Remove a NEVER() macro for a condition that is actually reachable following an OOM. dbsqlfuzz crash-6ef3cd3b18ccc5de86120950a0498641acd90a33.txt.
Change the 0x20000 bit (use analysis limit) to 0x10, meaning that this feature is on by default. The default analysis limit is changed to 2000 which is almost always sufficient for accurate analysis results.
Remove a few unsuitable scripts from the "veryquick" test suite. Also have every second testrunner.tcl process favour running test scripts that contain text like "testrunner: slow" before any others.
From test scripts, remove stray "breakpoint" commands and blank lines at the ends of files.
Add new test file cachespill.test.
Recognize certain standard datatypes ("INT", "INTEGER", "REAL", "TEXT", and "BLOB") and if a column has one of those datatypes, store the type part of the bit-field information in the Column structure to save space.
Disable a test case that (intentionally) does use-after-free, as it does occasionally cause problems even for non-sanitizer builds.
Refactor some of the global variables and commands used by tester.tcl.
Fix sqlite3_prepare() so that it only invokes the progress handler on every N-th call to sqlite3ProgressCheck(), where N is the progress handler step count. Also fix faulty asserts exposed by the ability to interrupt in the middle of sqlite3_prepare().
Enhance the documentation on sqlite3_stmt_readonly() to explain that EXPLAIN and EXPLAIN QUERY PLAN do not affect the return value. Add test cases to verify this. Add new test cases and requirements marks for complete requirements test coverage on this interface.
Revise how the Tcl system encoding is handled by the test suite.
Test case to show that the change fixes the original carray problem.
Back out the recent change to carray. The intent is to fix this problem in a different way so that it works for all table-valued functions.
Fix the carrayfault.test script so that it works in configurations that do not support virtual tables.
Fixes for OOM and IO error handling with temp file databases.
Add test cases for the NOT NULL/IS NULL optimization in CHECK constraints fix.
When processing a BETWEEN or CASE expression, avoid transforming a node of the original expression into a TK_REGISTER node. Instead, take a copy and use it instead. Fix for [1be72aab9].
Turn redundant registrations of the cksumvfs extension from a stack overflow into a harmless no-op. [gugs:/info/2026-07-29T06:28:31Z|Bug 2026-07-29T06:28:31Z]
Fix a problem that could cause a crash if a blob handle were closed after the associated database handle was closed using sqlite3_close_v2().
Reduce the size of test cases for the closure extension so that they run faster. The closure extension is not important for anything anymore and is retained mostly for historical reference. There is no point in burning CPU cycles testing it with large cases.
Additional test cases for the coalesce() and ifnull() functions.
New test cases added.
Correctly deal with an unknown collating sequence on an indexed DISTINCT query.
Improvements and simplifications to the equality seek logic. Tests are adjusted so that they all pass now.
Minor fixes. Tests are passing now.
Fix a bug with explicit collation sequences attached to a column reference expression that is on the right-hand-side of a binary comparison operator. (CVS 4187)
Propagate the COLLATE operator upward through function calls. Initial fix for ticket [ca0d20b6cdddec5e8].
Remove unused code. Test coverage enhancements. Modify the algorithm used to select column names for VIEWs of joins so that the constructed column names omits the underlying table names. (CVS 5386)
Fix a bug in the RTRIM collating sequence discovered while working on condition/decision branch coverage. Increase test coverage of the date/time functions. (CVS 5010)
Include the original text of the CHECK constraint in the error message for anonymous CHECK constraints.
Additional test cases.
Move the new test cases for this branch into a new *.test file.
Add a test case contributed on the mailing list that works in NGQP but fails in legacy.
Improved error messages from PRAGMA integrity_check. Identify the root of the tree when a problem is found in a b-tree, making it easier to track the problem to a specific table or index.
Add the SQLITE_DEFAULT_DEFENSIVE compile-time option. Fix up test cases so that they work with DEFENSIVE enabled.
Add a new sqlite3_test_control() that indicates that database files are always well-formed. Use this during testing to enable assert() statements that prove conditions that are always true for well-formed databases.
Change test results in corruptC.test to account for the added detail in the output of "PRAGMA integrity_check" from [b736519d3d2e93c7].
Have "PRAGMA quick_check" compare the number of entries in tables and indexes.
Remove the legacy_file_format PRAGMA. In its place, provide the SQLITE_DBCONFIG_LEGACY_FILE_FORMAT option to sqlite3_db_config(). Fix for ticket [6484e6ce678fffab]
Earlier detection of corruption in sqlite3BtreeDelete(). dbsqlfuzz a4c48c291d6e40157a1b749a05eaa7c7faf5a625.
Guard against oversized index entries in databases larger than 2GiB.
Update corruptM.test to account for the fact that the database schema may be loaded from within the "sqlite3" command for some test permutations.
Attempt to reduce divergence with begin-concurrent.
Do not reduce the estimated truth probability of LIKE and GLOB operators by quite so much. Fix a single test case whose output changed.
Allow a HAVING clause on any aggregate query, even if there is no GROUP BY clause. This brings SQLite into closer agreement with PostgreSQL and fixes the concern raised by [forum:/forumpost/1a7fea4651|forum post 1a7fea4651].
Omit the the count-of-view optimization if there is a HAVING clause. dbsqlfuzz 6a107e3055bd22afab31cfddabc2d9d54fcbaf69
If the sector size is greater than the database page size, SQLite journals all pages that lie within a sector before writing to any of them. This change ensure that a journal sync does not occur halfway through journalling the set of pages that belong to a single sector. (CVS 5605)
Update test helper procedure 'get_pwd' to handle the ComSpec environment variable being absent.
Add a test for the problem fixed by [bf44d73d3e].
Add tests to verify that the problem reported by forum post [forum:/info/2026-07-20T18:27:00Z | 2026-07-20T18:27:00Z] is only a problem on branch-3.53, not on this branch.
Disable multiplexing of master-journal files in the test_multiplex.c module.
Add the crashtest1.c program used to test the ability of the database to survive a program crash or power failure. Ticket #599. (CVS 1210)
New compile-time option SQLITE_MAX_SCHEMA and runtime limit option SQLITE_LIMIT_SCHEMA that put an upper bound on the number of objects in a database schema. Current default is 10 million.
Avoid factoring out constant expressions on the LHS of an IN(...) operator, as the IN(...) operation may affect the affinity of these values.
Do not allow ridiculous "columns=N" values in the (unused) csv virtual table in the extensions folder. [bugs:/info/2026-06-14T15:22:47Z|Bug 2026-06-14T15:22:47Z]
Fix test cases so that they all still work even with -DSQLITE_DQS=0.
After opening a non-covering index cursor, pass the corresponding table cursor to the implementation via sqlite3BtreeCursorHint().
Add the SQLITE_FCNTL_DATA_VERSION file control
Add "end of day/month/year" modifiers to date/time functions.
Date/time functions with no arguments (ex: date() or time()) should be non-deterministic. Fix for ticket [2c6c8689fb5f3d2f].
Enforce the restriction that 'unixepoch' only works as the first modifier after the time-value. This has been documented since 2004, but has never actually been enforced before. Also add new test cases for date/time functions with evidence marks.
Adjust the strftime() test in test/date4.test to remove flags not supported in musl libc if that environment is detected.
New date/time test cases to validate ancient dates.
Fix an incompatibility with -DSQLITE_OMIT_LOAD_EXTENSION=1 in dbdata.test.
Add test case for [29937081].
Initial code for a fuzzing tool on database file that works with the -fsanitize=fuzzer option of clang.
Enable the sqlite3_serialize() and sqlite3_deserialize() interfaces by default. Omit the SQLITE_ENABLE_DESERIALIZE option and replace it with the SQLITE_OMIT_DESERIALIZE option.
In the CLI, if a command-line argument names a file and the filename ends with .sql or .txt, then process that file as an SQL script. Use this feature for better testing.
Have the sqlite_dbpage module correctly handle constraints of the form "WHERE pgno=$pgno" when $pgno is an integer that cannot be represented as a signed, 32-bit value.
Improvements to the way that truncation is implemented in sqlite_dbpage().
Adjust the dbstatus2.test module so that it works on 32-bit builds in addition to 64-bit builds.
Fix unbounded whitespace skip in the decimal extension. [bugs:/info/2026-06-26T10:06:54Z|Bugs 2026-06-26T10:06:54Z]
Fix test cases due to an error message change.
Do not use the one-pass optimization on an UPDATE if there is a subquery in the WHERE clause, since if the subquery is hidden behind a short-circuit operator, the subquery might not be evaluated until after one or more rows have been updated. Fix for the problem reported by [forum:/forumpost/0007d1fdb1|forum post 0007d1fdb1]. This is the same problem that was fixed by [73f0036f045bf371] only for UPDATE instead of DELETE.
3 more coverage tests for btree.c. (CVS 5370)
Fix a bug in DELETE that might cause a segfault when deleting more than 40940 rows of data all at once. (CVS 2620)
Fix various problems in test scripts preventing "make test" from passing on F2FS file-systems with the "atomic-write" feature.
Correctly handle SELECT DISTINCT ... ORDER BY when all of the result set terms are constant and there are more result set terms than ORDER BY terms. Fix for these tickets: [c36cdb4afd504dc1], [4051a7f931d9ba24], [d6fd512f50513ab7].
Fix a long-standing problem with DISTINCT LEFT JOIN queries.
Consider an index for queries like "SELECT count(DISTINCT col) FROM ...", even if the index records are not smaller than the table records.
Revamp the QRF insert-mode optimization of [659ff6ab55802507]. The control value is now nMultiInsert. Multiple rows are added to each INSERT statement until the number of bytes in that statement exceeds the nMultiInsert value. The CLI uses a default value of 3000, which provides a good balance between speed and prepare-statement size. The output from ".dump" now loads nearly 2x faster in some cases.
Fix the zeroblob() function and related APIs so that they work with SQLITE_OMIT_INCRBLOB builds.
Fix stale requirement marks and fix a typo in the documentation for sqlite3_preupdate_hook().
Update evidence marks due to wording changes in requirements text. No changes to code.
Update requirement marks due to wording improvements in the documentation.
Allow "main" to be used to refer to the main database even after SQLITE_DBCONFIG_MAINDBNAME has been used to assign another alias.
Increase the precision of double → text conversions that happen in sqlite3_column_text(), or sqlite3_value_text(), or in the CAST() operator, or similar, so that round-tripping the value back to double results in exactly the same value.
Consistent error messages for excess trigger nesting.
More test-case adjustments for defensive mode.
Minor updates to requirements marks and documention. No changes to code.
Update some requirements marks to conform with improvements in the documentation.
Fix requirements marks that changed due to typo fixes in the documentation.
Handle recovery of virtual tables by recovering each shadow table individually, then writing the CREATE VIRTUAL TABLE statement directly into the sqlite_schema table.
Many more test cases fixed. Only a few remain.
Fix calls to sqlite3_wal_checkpoint_v2(SQLITE_CHECKPOINT_NOOP) so that they do not return SQLITE_MISUSE.
Change the error message text for SQLITE_ERROR to omit the part about "missing database" as that meaning is now obsolete (since approx SQLite 2.0).
Query planner optimization to detect empty tables in a join early and bail out without doing excess work.
Ensure that the database encoding is detected before the code generator gets too far down into byte-code generation and execution, but not so early that it interferes with initialization. [forum:/forumpost/bc75a4d20b756044|Forum thread bc75a4d20b756044].
Avoid opening cursors only required for reads that are optimized away by the exists-to-join optimization. Addresses report [bugs:/info/2026-07-25T08:39:23Z | 2026-07-25T08:39:23Z].
Fix a test case added by [1249eeb1b9759038] that does not work for the config=prepare permutation.
Do not report an sqlite3_error_offset() for errors that occur inside of views or triggers, since the text of those elements is not part of the original query.
Block deep recursion in test extension functions test_eval() and eval(). Does not affect deliverable code. [bugs:/info/2026-07-29T06:29:11Z|Bug 2026-07-29T06:29:11Z]
Update test file exclusive.test so that it works with the "journaltest" permutation.
Miscellaneous test coverage improvements. (CVS 4734)
Modify the permutations.test script so as to set any permutation specific configuration values before running each individual test script.
When using the OR-optimization on a loop created by exists-to-join, do the early-exit logic for the whole loop, not for each individual OR branch. Possible fix for forum post [forum:c8b205720c | c8b205720c].
Add extra tests for the changes on this branch.
Fix a logic error introduced by [cea8bf79e18d55a8] which caused "0 OR 2" to be evaluated as "2" instead of as "1". Problem reported at [forum:/forumpost/d5f32040c5d50d2d|forum post d5f32040c].
Update the sqlite3ExprCompare() routine so that it does not think "? IS NOT TRUE" is the same as "? IS TRUE". Fix for [d3e7f2ba5b3].
Add OOM test for the new code on this branch.
Add a test for the fixes on this branch.
Improve the integrity-check error message when floating point index values are off by one or two ULPs. Change the name of the eiib1.test test module to expridx1.test.
Do not run expridx2.test as part of the "journaltest" permutation, as it requires wal mode.
"test" targets on all makefiles use --verbose=file --output=test-out.txt. Add the new "quicktest" target to all makefiles - designed to run in under three minutes. The --quick option on releasetest.tcl now uses quicktest.
Minor fix the fallocate.test module change from [7cd56cad5efead5]
Fix some test cases on Windows.
Fix a harmless typo in the test case added by [29fc06465efb948f].
Add tests for the FILTER clause. And a bugfix.
Fix a memory leak that could follow an OOM in the new FILTER code.
Avoid double de-quoting of table names when processing RESTRICT actions in foreign key constraints. [https://bugs.chromium.org/p/chromium/issues/detail?id=1405220|Chromium 1405220].
Standardize the error messages generated by constraint failures to a format of "$TYPE constraint failed: $DETAIL". This involves many changes to the expected output of test cases.
Rename SQLITE_CONSTRAINT_RAISE to SQLITE_CONSTRAINT_TRIGGER. Put the extended constraint error codes in alphabetical order. Add many test cases for the extended constraint error codes.
Changes to busy2.test, corruptL.test and fkey5.test so that new test cases pass with all test permutations.
Fix problems in test script fkey6.test.
Do not commit an "OR FAIL" statement that causes foriegn key constraint violations.
Properly fix temp triggers created as part of FK processing to their schemas. Otherwise they may become confused by similarly named child tables in other attached databases. Fix for forum post [forum:636bd0180a | 636bd0180a].
Update a few test cases to account for the new error message formats.
Test script changes to account for the fact that the "p5" column in the EXPLAIN output is now an integer, not a text values containing a 2-digit hex value.
Add the test/fork-test.c test program.
Enhancements to the fp-speed-N.c programs, suggested by Andreas Kupries.
Remove a harmless unused variable from the fp-speed-2.c benchmark.
New sqlite3_db_config(SQLITE_DBCONFIG_FP_DIGITS) that let's the application specify the number of significant digits that double→text conversions will attempt to preserve.
Add a comment to test/fptest01.sql to remind us that failures in that script might not be the fault of SQLite.
Handle updating the only row of an FTS table correctly. Fix for [9fd058691].
Re-introduce the prefix-search optimization of [feef1b15d6], which was lost in a reorganization of FTS3 code.
Fix a broken assert() in fts3. Also some test script issues causing failures with builds that do not support fts3.
Add new sqlite3_prepare_v3() flag SQLITE_PREPARE_NO_VTAB, for preparing statements that are not allowed to use any virtual tables. Use this to prevent circular references in triggers on virtual table shadow tables from causing resource leaks.
Make sure errors encountered while initializing extensions such as FTS4 get reported out from sqlite3_open(). This fixes a bug introduced by check-in [9d347f547e7ba9]. Also remove lots of forgotten "breakpoint" commands left in test scripts over the years.
Fix for [9861b74ab9]. Correctly handle strings with zero tokens in the fts3 offsets() function.
Add extra tests for parsing of whitespace in tokenizer declarations,.
Start reworking fts3 code to match the rest of SQLite (code conventions, malloc-failure handling etc.).
Replicate the fts2*.test files as fts3a*.test, and convert fts2 to fts3 in the text of the files. (CVS 4251)
Updates to FTS4 to improve performance and make more accurate cost estimates for prefix terms.
Skip tests that require UTF-16 support when compiled with SQLITE_OMIT_UTF16.
Change the fts3 snippet function to return (hopefully) more relevant snippets in less time.
Fix a test script issue in fts3ao.test.
Check for whether or not it is safe to use non-innocuous functions as the function is being coded, not when its name is resolved.
Further fixes for running [make devtest] with Fil-C.
Fix a case in fts3auto.test that fails for SQLITE_DISABLE_FTS4_DEFERRED builds.
Do not assume that text parameters passed to fts4aux queries do not contain embedded nul characters.
Add test for fts3 compress= and uncompress= options.
Add the xIntegrity method to the sqlite3_module object. Implement this method in RTREE, FTS3/4, and FTS5 so that "PRAGMA integrity_check" also verifies the correctness of shadow tables associated with those virtual tables.
Fix to test case in fts3corrupt.test. No changes to source code.
Fix a buffer overread in fts3 that could occur when decoding a corrupted record.
Enable DEFENSIVE mode by default for tests. This requires lots of case of turning DEFENSIVE off in order to dodgy things to the database for testing purposes. No all of those cases are yet handled, so "make test" does not run to completion.
Improved detection of corrupt freelist chains on btree pages. Plus, add assert()s to verify that the min-heap does not overflow inside of PRAGMA integrity_check.
Fix a cast in fts3_write so that it is applied as intended. Bug [bugs:/info/2026-06-19T07:56:23Z | 2026-06-19T07:56:23Z].
Fix a buffer overwrite in fts3 that could occur while processing NEAR queries against corrupt records. Bug [bugs:/info/2026-06-11T23:11:26Z | 2026-06-11T23:11:26Z].
Fix the size of an allocation in fts3 to take into account that when merging a phrase doclist, each entry may grow by up to 1 byte if the rhs position of the merged lists is stored. Bug [bugs:/info/2026-06-26T08:08:39Z | 2026-06-26T08:08:39Z].
Fix a problem with fts3 auxiliary functions and one or more NEAR expressions ORed together.
Add new test file fts3defer3.test.
Avoid attempting to call savepoint related methods on deleted sqlite3_vtab objects. Fix for [48f299634a].
Fix a typo in the result of one of the new test cases.
Add some simple tests to make sure that the different fulltextFilter query paths are being exercised. (CVS 5498)
Make the test-use-only SQL function fts3_exprtest() (available only if compiled with SQLITE_TEST) more resistant to out-of-bounds inputs. [bugs:/info/2026-08-02T12:28:28Z|Bug 2026-08-02T12:28:28Z] and [bugs:/info/2026-08-02T12:31:40Z|bug 2026-08-02T12:31:40Z].
Update fts3 so that expressions to the left and right of a NOT operator are balanced. This prevents relatively small expressions (a dozen terms or so) that are children of NOT operators from triggering the "expression tree is too large" error.
Fix a test case in fts3expr4.test to account for different locales.
Fix a use-after-free in fts3 that could follow an optimize() in the middle of a SELECT statement when the hash table is non-empty.
Fix a problem handling OOM errors in fts3 that could occur when parsing multi-token strings.
Fix another test case error message similar to those fixed in [b3d6b3c3].
Ensure the fts3 xIntegrity method correctly returns error codes unrelated to corruption or missing SQL elements.
Have FTS3 ignore ^ prefixes. The ^ syntax is only supported on FTS4 tables.
Fix an fts3 problem caused by reducing the page size using the undocumented "nodesize" option, then running an incremental-merge.
Avoid expiring prepared statements in the middle of an integrity-check.
Relax query flattener constraint (3b) and thereby allow flattening the RHS of a LEFT JOIN even if the RHS contains a virtual table. This was previously disallowed by [9dbae1df75219e2a] as a performance optimization. It turns out that the constraint causes performance issues, and we do not have a record of any performance issue that it solves.
Cut over the next generation query planner. Increase the version number to 3.8.0.
Fix a null pointer deference that can occur on a strange matchinfo() query.
Fix an integer overflow in fts3 causing a usan error.
Fix a crash that could occur in fts3 when processing a corrupt database.
Fix a problem with fts3 prefix terms within phrase queries on "order=DESC" tables with a mix of negative and positive rowids.
Fix test cases for the new EXPLAIN QUERY PLAN format. Add the wherecosttest tool. Other fixes to logarithm cost.
Adjust the fts3rank.test module so that it works on big-endian systems (hopefully - I don't have a big-endian machine to test the change on.)
Fix problems to do with using both OR and NEAR operators in a single expression.
Return an empty string if an fts3 snippet() is requested for an out-of-range column index. Bug [bugs:/info/2026-07-29T06:30:35Z | 2026-07-29T06:30:35Z].
Fix a "shift exponent is too large" usan error that could occur in the fts3 snippet() function when a query phrase contains more than 64 tokens.
Fix the fts3varint.test script so that it works even on versions of TCL for which Tcl_GetWideIntFromObj() does not work.
Improve corruption detection in fts3 shadow tables earlier in order to prevent an assert() from failing.
Add the SQLITE_PREPARE_FROM_DDL flag to sqlite3_prepare_v3(). Use this to prevent fts3/4 tables in non-trusted schemas from calling unsafe SQL functions.
Have fts4 full-text queries consider "docid<?" and similar constraints.
Remove possibly stray output from various tests.
Ensure that the xIntegrity methods of fts3 and fts5 work on read-only databases.
Add tests for incremental merge code.
Update fts3/4 so that the 'merge=X,Y' command merges at least, instead of exactly, Y segments from a single level. This matches the documentation. 'merge=X,0' is, as it was in 3.11, an error.
Fix a typo in fts3/4 debugging code allowing 'maxpendinXY' to act as a synonym for 'maxpending=' in special INSERT statements.
Optimization for "SELECT min(x) FROM tbl" where "x" is indexed and NOT NULL. This also allows similar queries on NOT NULL virtual table columns to be optimized.
Ensure that multiple updates of the same FTS4 row (i.e. the row with the same rowid) within a single transaction are written to separate segments. Fix for [d6ec09ec].
Add extra tests for the handling of corrupt records in fts3.
Merge changes from trunk into the alter-table-drop-column branch.
Fix cut-and-paste error in test file fts4umlaut.test.
Add extra test for handling of embedded nul characters in the fts4 unicode61 tokenizer.
Allow SQLite to work on Win32 with SQLITE_OS_WINNT=0 as long as WAL is disabled.
Avoid slowdown when exprNodeIsConstant() is called on deeply nested SQL functions.
Remove all code that makes use of the C-language "long double" datatype.
Do not factor out constant functions into the initialization section at the end of the prepared statement, be cause if they throw an exception, it will abort the statement even if the function is never called. Better to put constant functions in an OP_Once block.
Remove an incorrect ALWAYS() macro from the implementation of the internal exprNodeCanReturnSubtype() routine so that it works with zero-argument deterministic functions like pi().
Add test cases for functions named the same as join keywords.
Fix a bug in concat_ws() in which an initial empty string was treated as if it was a NULL value.
Make sure errors in the FROM clause of a SELECT cause analysis to abort and unwind the stack before those errors have a chance to mischief in the "*" column-name wildcard expander. Fix for ticket [32b63d542433ca67].
Fix another problem found by Matthew Denton's new fuzzer.
Fix a case in "fuzz.test" that could fail, as non-deterministic functions may no longer appear in CHECK constraints.
Add the strdup() SQL function extension for use in testing.
Fix a faulty assert() statement identified by [forum:/forumpost/0b91a75039|forum post 0b91a75039].
Add the --info option to the fuzzcheck test utility.
Add a corrupt database to test/fuzzdata3.db to validate the previous check-in.
Fix an overzealous assert() statement discovered by OSSFuzz.
Fix a faulty assert() in the validation logic for the LEFT JOIN strength reduction optimization. Problem found by OSSFuzz.
Change the debugging "json_parse(X)" function so that it shows a more complete description of the JsonParse object on standard output and returns the mimified JSON. Former behavior was to return the text of a decode of the aNode array.
Remove a NEVER() macro and add a test case to cause its argument to be true.
Fix a problem in the sqlite_dbpage() table-valued function when it is trying to truncate a file in locking-mode=EXCLUSIVE and the file was obtained via sqlite3_deserialize(). Problem found by dbsqlfuzz.
Fix dequoting error on the instantiation parameters of the non-deliverable extension virtual table "fuzzer. [bugs:/info/2026-06-23T05:51:36Z|Bug 2026-06-23T05:51:36Z].
Avoid running some particularly time-consuming tests as part of veryquick.test.
Add OOM test case associated with the fix in the previous commit.
Try to prevent false positives in fuzzinvariants.c due to scalar subqueries.
Fix memory leaks in the amatch extension. Add a few simple test cases.
New test case for the HAVING fix of check-in [f62f983b56623f0e].
Fix then handling of the (oversized) integer literal -0x8000000000000000.
Fix a problem with VACUUM and __hidden__ columns.
Similar fix to the previous check-in, but this time for sqlite3_preupdate_new().
Experimental change to invoke the preupdate hook when WITHOUT ROWID tables are written.
Update the utf-8 decoder in the ICU extension to treat invalid sequences as codepoint 0xFFFD, matching the core. Report [bugs:/info/2026-06-03T04:04:46Z | 2026-06-03T04:04:46Z].
In the ieee754 extension, render -0.0 as 'ieee754(-1,-3071)' instead of 'ieee754(1,-3071)' as that makes the sign clearer. Both strings still convert back to -0.0. Note that negative zero and positive zero are distinct values in ieee754. [forum:/forumpost/1eab7e4a08|Forum post 1eab7e4a08].
Change the CLI so that the default "--title" is "always" instead of "on" for some display modes. This check-in also include a fix to "--title always" for the "markdown" display mode.
CLI: The .imposter command matches the index name regardless of case. Minor fixes to .check.
Improvements to imposter tables: (1) They are read-only unless writable-schema is enabled. (2) Because they are now read-only, the ".imposter" command in the CLI no longer requires the --unsafe-testing command-line option. (3) Imposter tables do not participate in a PRAGMA integrity_check and hence do not cause false-positive errors. However, you can still do an integrity_check on the the imposter table itself by naming the imposter table as the argument to integrity_check.
Remove leftover debugging commands (breakpoint and btree_breakpoint) from test scripts. (CVS 5400)
Fix (make test) with SQLITE_OMIT_COMPOUND_SELECT. Ticket #3235. (CVS 5530)
Ignore any DISTINCT qualifier on a SELECT statement on the RHS of an IN(...) expression. Forum post [bugs:/info/2026-07-25T08:40:13Z | 2026-07-25T08:40:13Z].
Slight performance improvement for the new code on this branch.
Fix the IN-early-out optimization so that it works even for the corner case where the NULL bypass fires before the affinity of the LHS operator has been set. Fix for the problem described in [forum:/forumpost/6a3ec138e9|forum post 6a3ec138e9].
When processing a vector IN(...) term in a WHERE clause, do not add individual terms for each column if the RHS of the IN(...) is a query that is expected to do the special min-max aggregate behaviour. Possible fix for [bugs:/info/2026-08-03T09:05:06Z | 2026-08-03T09:05:06Z].
Handle a real OOM condition when incrblob2.test is run on a low-memory machine.
Fix a minor problem in the Tcl "incrblob" command. This does not affect the SQLite core.
Adjustments to test/incrblob4.test so that it works on both Linux and Mac in spite of error message differences between those platforms. Minor change to termIsEquivalent() to provide 100% MC/DC.
Fix an assert() that can be false when doing an incremental vacuum on a corrupt database file. dbsqlfuzz cced0668cfd4da4eb2382cb9dd26c17c64aaff76.
Fix a problem in incrvacuum_ioerr.test. Do not run ioerr6.test with an in-memory journal.
Continue to support the (broken) legacy syntax of allowing strings for column names in CREATE INDEX statements and in UNIQUE and PRIMARY KEY constraints.
Minor fix to test/index9.test so that it can be invoked with other index tests using a wildcard.
Fix to the interaction between indexes-on-expressions, subtypes, and the unary "+" operator. This is a continuation of the prior fix from check-in [d75c08c8416bde3f]. This enhanced fix is prompted by [bugs:/info/2026-07-24T08:42:47Z|Bug 2026-07-24T08:42:47Z].
Fix a NULL pointer dereference that can occur when misusing a extension virtual table that was created for testing purposes. [bugs:/info/2026-06-23T05:32:49Z|Bug 2026-06-23T05:32:49Z]
Experimental change to explain query plan to identify covering indexes on expressions.
In sqlite3NestedParse() be sure to detect all SQLITE_NOMEM and SQLITE_TOOBIG errors and to distinguish between them.
Disable the "init.test" test script when compiled with SQLITE_THREADSAFE=0.
Fix an obscure problem with "INSERT INTO tbl(cols) SELECT" statements where the SELECT is a compound with an ORDER BY and "cols" is a strict subset of tbl's columns.
Move the asynchronous IO code from src/test_async.c to ext/async/. Refactor it to be a standalone module and to support windows. (CVS 6539)
Fix the insert4.test test module so that it works when SQLite is compiled with SQLITE_OMIT_VIRTUALTABLE.
Enable an ORDER BY clause to refer to columns in outer queries.
Fix a segfault that could follow an OOM when querying a table that has one or more columns with default values "true" or "false".
Update test script instrfault.test to account for the fact that bound blob values cast to text values are now intepreted using the text encoding of the database, instead of always as utf-8.
Fix the parse_create_index() SQL function created by the incremental integrity_check extension so that it works for widely correct CREATE INDEX statements. [bugs:/info/2026-07-05T12:00:57Z|Bug 2026-07-05T12:00:57Z]. Also fix the extension so that it removes the parse_create_index() function. Add the sqlite3_intck_register() API function so that the parse_create_index() function can be more easily tested.
Add a new sqlite3_is_interrupted() interface that can be used by long-running app-defined functions and similar to see if they need to exit early due to an sqlite3_interrupt() call.
Update interrupt2.test to avoid using Tcl_GetCommandInfo() from within calls to Tcl_DeleteCommand().
Fix boundary cases of rowid lookup using very large floating point values - values near the minimum and maximum 64-bit signed integer. [forum:/info/2026-07-19T07:31:46Z|Forum 2026-07-19T07:31:46Z].
Fix a problem with applying integer affinity to a MEM_IntReal value. Forum post [forum:/forumpost/d270125fae|forum post d270125fae].
Update a couple of test cases to account for the fact that ROLLBACK does not always abort all running SELECT statements.
Additional test coverage improvements. Test coverage now stands at 98.73%. (CVS 4731)
Enhance the omit-noop-join optimization so that it is able to omit a chain of noop-joins. Optimization improvement suggested by [forum:/forumpost/11a53f2bad|forum post 11a53f2bad].
Ensure that the WhereInfo.revMask bitmap is adjusted when tables are removed from the FROM clause by the Omit-Noop-Join optimization of [0cd82ee9a8413cf1]. Fix for the issue described by [forum:/forum/8a1e467e905b8d27|format post 8a1e467e905b8d27].
Continued refactoring of the name resolution logic and query optimizer. (CVS 2236)
Add the SQLITE_OMIT_TEMPDB compile time macro. (CVS 2427)
Fix a buffer overread found by OSSFuzz that could occur if a WITHOUT ROWID table with many columns was NATURAL JOINed against itself.
New FULL JOIN test cases. No changes to code.
Update test scripts to account for [8fcea4cd].
Fix the query flattener so that it does not flatten a RIGHT or FULL JOIN into any position of the outer query other than the first.
Generalize the LEFT JOIN strength reduction optimization so that it works for RIGHT and FULL JOIN as well. Rename it to the "OUTER JOIN strength reduction" optimization.
Add 512 new join test cases derived from PostgreSQL output.
Tweaks to the name resolution on parenthesized joins. A small number of tests fail now due to extra columns appearing in the expansion of "*".
Corrections to the header comment to the new joinE.test script. Add the generator TCL as a comment at the bottom of the script.
More JOIN test cases inspired by the problem fixed in [3869fd9a2b9483cb].
Always take a copy of a value used to drive an index as part of a RIGHT JOIN loop. Otherwise, the RIGHT JOIN loop and the body of the loop it jumps back into may interfere with each other. Possible fix for [bugs:/info/2026-07-29T05:33:50Z | 2026-07-29T05:33:50Z].
When two tables are joined by USING, the affinity and collating sequence of the join column will be the same as one or the other of the columns in the two tables (which are hopefully the same).
Disable PRAGMA journal_mode=OFF when SQLITE_DBCONFIG_DEFENSIVE is turned on. Ticket [f4ec250930342e0c].
Avoid unsigned integer overflow when evaluating an array index in a JSON path expression. [forum:/forumpost/2026-01-27T14:18:49z|Forum post 2026-01-27T14:18:49z].
Fix the jsonb_group_array() and jsonb_group_object() functions so that they return JSONB as they should, and not text JSON, when the array or object is empty. [forum:/forumpost/2026-01-25T00:47:06z|Forum post 2026-01-25T00:47:06z].
Fix a problem with json_patch() when one side or the other is JSON5. dbsqlfuzz bc10593a4ba8e7a7862593532285be31f00f8e41
Add test cases for json_pretty().
If a BLOB looks like JSON when cast to text, then treat it as if it really were JSON. This replicates a long-standing bug in the JSON processing routines, and thereby avoids breaking legacy.
Raise an error if any PATH argument to json_array_insert() is not the path of an array element. Add some test cases for json_array_insert().
Allow control characters in JSON5 string literals. [forum:/forumpost/05182119f69c3a92|Forum thread 05182119f69c3a92].
Fix a bug in the parsing of some corner-case JSON PATH strings that contain escaped double-quotes.
Add tests that verify that keywords WITH, WITHOUT, and RECURSIVE can still be used as table and column names.
Fix harmless typo in a comment.
Add additional test cases and requirements evidence marks for WITHOUT ROWID.
Make sqlite3_count_changes() and total_changes() work with "DELETE FROM <table-name>". (CVS 5844)
Fix a compilation error in test/lemon-test01.y, reported in [forum:f0ad095705|forum post f0ad095705].
Fix a problem in the LIKE and GLOB operators that may occur when the character immediately following a "%" or "*" wildcard is U+80. Reported by [forum:61bf7ccbdf].
Fix the processing of implied LIMIT clauses when flattening a compound query.
Always convert 32-bit integer literals into EP_IntValue notation, even if they contain "_" separators.
Fix a problem in the previous commit with hex literals that start with "0X" instead of "0x".
Add the sqlite3_cancel_auto_extension(X) interface which will undo a prior call to sqlite3_auto_extension(X).
Fix problems with running the async.test script.
Back out check-in (6380). Replace it with a proper fix to the xFullPathname method in the async VFS. (CVS 6398)
Avoid running some new tests in lock5.test with the inmemory_journal permutation.
Fix minor test suite problems causing errors on OSX.
Fix a test script problem causing errors with Tcl 9.
Avoid incrementing the SQLITE_LOOKASIDE_MISS_SIZE stat before sqlite3_open() returns. Fix test script problem in lookaside.test.
Omit the antiquated and long-unsupport async extension since it has been superseded by WAL mode for over a decade.
Attempt to optimize virtual table queries with 'OR' expressions in the WHERE clause. (CVS 6527)
In SQLITE_ENABLE_BATCH_ATOMIC_WRITE builds on F2FS file-systems, invoke SQLITE_FCNTL_ROLLBACK_ATOMIC_WRITE if an SQLITE_FCNTL_COMMIT_ATOMIC_WRITE call fails. Also, do not use an atomic transaction to create the initial database. This is because if an error occurs while writing to the db file, any changes to the file-size do not seem to be rolled back automatically. The only time this matters is when the file was 0 bytes in size to start with.
Add the memory fault simulator to mem5.c. Enable soft heap limit on mem5.c. Limit the size of hash tables and the vdbefifo when using mem5.c. (CVS 4795)
Update a test case in malloc5.test to take into account that malloc() sometimes returns slightly more space than requested.
Fix the output labels on the tests in malloc9. (CVS 4966)
Change all.test, quick.test and permutations.test so that they use a separate interpreter for each test file.
Bring test coverage up to 99%. (CVS 5522)
Add a test case for the fix in [a596b7c6cc].
More coverage improvements. (CVS 6148)
Fix a crash that could follow an OOM condition in the instr() SQL function.
Update the expected error messages in some OOM test cases to account for [44d77a7f807].
Fixes for the generated "mallocs.tcl" and "leaks.tcl" scripts generated by running tcl tests with the --malloctrace=1 option.
Fix issue with mem5 allocator when min request size is larger thatn 2^30.
Simplify the page recycling condition in pcache1. Fix test cases to work with the latest changes.
Fix the memdb1.test test module so that it runs correctly on Windows.
Fix a problem in the in-memory journal code that could occasionally lead to a segfault when a sub-transaction that modified zero pages was committed.
An attempt to enhance PRAGMA integrity check so that it does data type checking on non-STRICT tables. Specifically: (1) Columns with TEXT affinity should not contain numeric values, and (2) columns with numeric affinity should not contain text values that can be converted to numeric.
Fix problems with test scripts preventing them from running with SQLITE_DEFAULT_MEMSTATUS=0 builds. Or builds without SQLITE_ENABLE_STAT4.
Enhance the generate_series() table-valued function such that it is able to recognize equality and inequality constraints on the "value" column and optimize its operating accordingly.
Also prohibit the use of rowid from a subquery. Add the SQLITE_ALLOW_ROWID_IN_VIEW compile-time option to restore legacy behavior in case somebody actually needs it.
Change the weighting of binary searches on tables to 1/10th the cost of a search on an index. Change the assumed reduction in search space from a indexed range constraint from 1/3rd to 1/4th. Do not let the estimated number of rows drop below 1.
Add tests to ensure that this branch really does fix ticket [f8a7060ece].
Allow underscores to occur in hex literals.
Update tests to work with SQLITE_ALLOW_ROWID_IN_VIEW.
Minor adjustments to get Tcl9-based testing working on Macs.
Add the SQLITE_LIMIT_PARSER_DEPTH value for sqlite3_limit(). This isn't something that many applications will need, but it is useful for testing.
Get the build working with -DSQLITE_OMIT_UTF16=1. Ticket #2314. (CVS 3865)
Have sqlite3_set_errmsg() return SQLITE_MISUSE if a NULL db handle is passed to it, as documented.
Update mjournal.test so that it works on windows.
Slight adjustment to test results for Windows in mmap1.test due to the previous check-in.
Cygwin-centric test script tweaks from Jan Nijtmans.
Do not attempt to run mmapcorrupt.test with builds that do not support mmap().
Update some test cases to work with SQLITE_OMIT_VIRTUALTABLE and DEFAULT_AUTOVACUUM builds.
Make the (legacy, deprecated) ".header" command in the CLI responsive to the "always" title mode. Clean up title mode and define its operation with improved comments in the TCL interface and in the CLI. Add the "-title auto" option to the CLI.
Add pragmas "multiplex_enabled", "multiplex_chunksize", and "multiplex_filecount" to the multiplexer implementation.
Add a hard limit to the number of chunks a multiplexed database may consist of if ENABLE_8_3_NAMES is defined.
Update multiplex3.test to account for the fact that the multiplexor xDelete method may return an error even if it manages to delete the first chunk of a file.
Clearification of some documentation text. Added requirements marks.
Rename SQLITE_ENABLE_MULTITHREADED_CHECKS to SQLITE_THREAD_MISUSE_WARNINGS. Run test cases with that option. Also add the SQLITE_THREAD_MISUSE_ABORT option.
Remove the SQLITE_MUTEX_APPDEF compile-time option. The SQLITE_THREADSAFE=0 option always removes all mutex code. For application-defined mutexes only, use SQLITE_THREADSAFE=1 with SQLITE_MUTEX_NOOP=1. Ticket #3421. (CVS 5779)
Adjust a few tests that don't work even with the new floating point comparison routine.
Skip recently added test cases in nolock.test when running in the inmemory_journal permutation.
Change notify2.test to check that sqlite3_blocking_step() uses CPU more efficiently than sqlite3_step(), not that it results in greater overall throughput for any specific number of threads.
In the cost metrics of the query planner, the estimated number of output rows from an EXISTS-to-JOIN loop should not be more than 1. [forum:/forumpost/989880d0aa|Forum post 989880d0aa].
Back out the incorrect optimization of check-in [e51ecadcbdef5ce6] as ticket [5c4e7aa793943803] reports a case where the optimization does not work.
Fix problems with expressions like "(?,?,?) IN (SELECT c,b,a FROM ...)" when there is an index on columns "c", "b" and "a", but not in that order. Bug [bugs:/info/2026-06-04T07:02:53Z | 2026-06-04T07:02:53Z].
Fix text-to-numeric type casting so that it works correctly on UTF16 strings that contain characters where the LSB is numeric but the MSB is non-zero. Ticket [689137afb6da41]
More test cases for indexes on large numeric values.
Add the optfuzz.c program for verifying the query planner using a fuzzer. This is an initial code check-in.
Update the query planner to recognize more cases where ORDER BY clauses can be optimized out. Add test cases to verify correct behavior of the ORDER BY optimization when the covering-index-scan optimization is disabled. Fix a harmless compiler warning in the TCL interface.
Fix an incorrect assert() statement that was added yesterday. Tickets [41c1456a6e61c0e7] and [fb8c538a8f57ae2a].
New test case for block-sorting.
Add test cases to ensure correct operation of joins with a virtual table that include DISTINCT and ORDER BY clauses. Verification for ticket [388d01d4bb8f9].
There are asserts in place now that will prevent a recurrence of ticket [f97c4637102a3ae7]. Nevertheless, it is good to add some test cases as well.
Fix the orderby9.test case so that it works with 32-bit versions of TCL
Allow SQLite to omit redundant ORDER BY sorts in the case where a SELECT statement has GROUP BY and ORDER BY clauses that use the same expressions, even when the ORDER BY expressions are marked "DESC".
Fix handling of COLLATE. Add test cases for the same. Code cleanup for improved understandability and maintainability.
Reduce the maximum size of LIKE and GLOB patterns in the ossfuzz.c test module to avoid false-positive infinite loop reports from OSS-Fuzz based on long and complex fuzzer-generated LIKE/GLOB patterns that are not actually infinite loops, but which do take a long time to resolve.
Fix utility compilation issues with MSVC.
Help-text and comment fixes in the CLI. Add the output-redir-test.txt testing script.
Fix the pager2-3.1 test case so that it does not run if a required dependence (shared-cache) is omitted from the build. Fix for [forum:/forumpost/7a028538a7|forum post 7a028538a7].
More test-case changes so that everything works when the reserved_bytes value in the header is non-zero.
Fix a faulty assert() in the btree part of the "PRAGMA page_size = ?" code.
Defer the bulk pcache1 memory allocation until the first page allocation request. Limit the size of the pcache1 bulk allocation to the cache_size setting. Deallocate the bulk allocation on a sqlite3_db_release_memory() request, if the bulk allocation is completely unused.
Fix a crash that could be caused by configuring the pager-cache with a bulk allocation too small to fit even one page. Bug [bugs:/info/2026-06-04T07:03:12Z | 2026-06-04T07:03:12Z].
Use tail recursion on the larger of the two partitions when doing a quicksort as part of the implementation of the median() function, to avoid excess stack usage on pathological inputs. [bugs:/info/2026-06-03T07:26:42Z|Bug 2026-06-03T07:26:42Z].
Allow a FROM clause in UPDATE statements.
Fix "PRAGMA data_version" so that it works the same way with locking_mode=PERSIST and journal_mode=PERSIST configured. Fix for 7a458c2a5f.
Fix a memory error in test logic introduced by [8704034254938662].
Enhance PRAGMA function_list so that it shows all instances of each FuncDef, the number of arguments, the encoding, the type, and the flags. Use this capability to locate and fix incorrect function flags in the standard build.
Fix pragma6.test so that it works with ENABLE_OVERSIZE_CELL_CHECK builds.
Fix a problem causing "PRAGMA integrity_check" to disable the xfer optimization for subsequent VACUUM operations on tables with one or more CHECK constraints. This could result in VACUUM producing slightly larger database files.
The prefix_length() function should stop at the first NUL terminator. [bugs:/info/2026-06-03T07:42:00Z|Bug 2026-06-03T07:42:00Z].
Fix the new %J and %j formats so they work correctly with a zero precision.
Fix some of the new date/time function features to comply with the spec. Update requirement marks.
More test output refinements.
Ensure that the query flattener does not change an ON clause term to a WHERE clause term.
Adjust QRF to generate lower-case HTML output with the SQLITE_STYLE_Html style setting.
Further testing and bug fixing.
Update test cases to work with the new box format and with --quote relaxed.
New test case for bSplitColumn in QRF.
New test cases for QRF
Add the experimental "query_only" pragma.
Add test file pager1.test, containing tests of inter-process locking in non-wal mode.
Documentation improvements and additional test cases.
Improved error message when a double-quoted string is used and it seems likely that the user wanted a single-quoted string literal.
Add test cases that verify evaluation of randomly generated SQL expressions. (CVS 6029)
Changes to various test scripts so that veryquick.test runs with OMIT_COMPOUND_SELECT defined.
Change the name of the OTA extension to RBU: Resumable Bulk Update.
Fix the behavior dot-commands that appear as command line arguments to the CLI so that their effect persists into subsequent commands on the command line. This fix also improves error messages caused by command line arguments. [forum:/forumpost/2026-03-10T19:26:06z|Forum post 2026-03-10T19:26:06z].
Update the regexp extension so that the "-" character may be escaped with a backslash. Forum post [forum:c5e7358f82 | c5e7358f82].
Limit the complexity of a REGEXP pattern using SQLITE_LIMIT_LIKE_PATTERN_LENGTH
Fix an assert() and potential buffer overrun in fts5 that could occur if the database was corrupt.
Update test script reservebytes.test so that it works with the "prepare" permutation.
Add tests for changing the database encoding via RESET_DATABASE/VACUUM. And test that it is not possible to trick another connection with this.
Fix a faulty assert() in the "AS" alias resolution logic of the parser.
Avoid dropping RETURNING triggers when the schema is reset while preparing a statement.
Add an OOM test case for the issue with dropping RETURNING triggers when the schema is reset while preparing a statement that uses an eponymous vtab.
Improved rounding policy.
Fix the rowallock.test script so that it works with builds that do not support mmap mode.
In the rowhash.test, make sure global variables are cleared prior to use.
Fix all test cases so that they work with SQLITE_ALLOW_ROWID_IN_VIEW.
When comparing row values that are sub-selects, do not consider the collation sequences of the expressions returned by the sub-select when determining the collation sequences to use for the comparisons. i.e. in "(a, b)=(SELECT c, d)", do not consider the collation sequences of "c" or "d". Fix for problem [forum:/info/2026-08-09T09:33:49Z | 2026-08-09T09:33:49Z].
Add test cases to rowvalue2.test.
Do a better job of not generating unnecessary Bloom filters associated with IN operators.
Fix a SQL NULL handling bug in the vector IN operator code generation.
Fix the vector BETWEEN operator so that it only evaluates the left-most vector expression once. Add support for vector comparisons in the CASE operator.
Improve the error message in cases where there is a row-value on the LHS of an IN() operator, the RHS is a list (not a sub-select) and at least one element of the list is not a row-value with the correct number of elements.
Fix a problem with using views in SQLITE_OMIT_VIRTUAL_TABLE builds. Also some test case fixes required for the same builds.
Fix a couple of memory leaks in r-tree that can occur following an OOM condition.
Modify wordcount so that timer information appears on standard error instead of standard output. Rename the run-wordcount.bash script to run-wordcount.sh and simplify it so that it stands a better chance of running on non-GNU systems.
Further fixes to comments in sqlite3recover.h. Also rework some data structures in sqlite3recover.c.
Add the "wal" permutation to run existing test files savepoint.test and savepoint2.test in WAL mode.
Change savepoint4.test to limit database growth. Otherwise the test can take a very long time to run, depending on the prng. (CVS 6737)
Reinitialize page 1 of the database file following a ROLLBACK TO of a transactional SAVEPOINT on an initially empty database. (CVS 6103)
Attempt to reduce divergence with the wal2 branch.
Make the SQLITE_DBCONFIG_STMT_SCANSTATUS option on by default.
Fix an incompatibility with Tcl 9 in scanstatus2.test.
Immediately reset all pending prepared statements on any call to sqlite3_set_authorizer(), even if the authorizer is being disabled.
Simplify wording of backup API error message. Decapitalize some other error messages. (CVS 6256)
Updates to test procedures so that they all work with encryption. No changes to the core SQLite code.
Avoid leaving view-definitions with an incomplete set of column names/types in the in-memory schema if an OOM strikes while allocating the same.
Update tests to deal with SQLITE_FAST_SECURE_DELETE.
Avoid having OP_SeekScan jump over an OP_IdxGT or OP_IdxGE that follows the OP_SeekGE opcode. Fix for [b50528af4468237c].
Improve EXPLAIN QUERY PLAN output and comments on bytecode listings by distinguishing between "subquery" and "join" and using consistent names across EQP and bytecode.
Further refinements to table order selection on join query planning.
When doing the optimization that attempts to avoid sorting on a GROUP BY, do not assume that the values in an index on an expression are non-NULL. Bug discovered by Wang Ke's fuzzer and reported at [forum:/forumpost/74330094d8|forum post 74330094d8].
Do not let the number of terms on a VALUES clause be limited by SQLITE_LIMIT_COMPOUND_SELECT, even if the VALUES clause contains elements that appear to be variables due to the use of double-quoted string literals. [https://issues.chromium.org/issues/358174302|Chromium issue 358174302].
Fix another test case to work with union-by-merge.
Change EXPLAIN QUERY PLAN output to say "USE TEMP B-TREE FOR LAST TERM OF ORDER BY", or "LAST N TERMS OF ORDER BY", instead of "RIGHT PART OF ORDER BY".
Minor cleanups of the compound-subquery flattening logic. New test cases added for joins the compound subquery.
Do not perform the omit-unused-subquery-columns optimizations on a subquery that is DISTINCT, as that can lead to incorrect results.
Fix a faulty assert() statement in the name resolver associated with the optimization that converts compound selects with ORDER BY COLLATE into subqueries.
Change an OP_SCopy into an OP_Copy in a case where the destination might be used after the source has changed.
Avoid excess stack usage when a VALUES clause with lots of rows occurs within a scalar expression. This fixes a problem discovered by OSSFuzz.
Do not disable unused columns in a UNION ALL sub-query if any component of the sub-query is DISTINCT.
Change the names of the stream interface APIs to be of the form "_strm" instead of "_str". In other words, added an "m" to the end, to try to make it clear that we are talking about a "stream" and not a "string.
Add the sessionfuzz test program and data obtained from a week of running AFL. Automatically run this test program on any "make test" on unix.
Update test/c/snprintf1.c to test the result of the sqlite3_snprintf() call. Also add an SQLITE_OMIT_AUTOINIT configuration and update C tests to account for it.
Do not allow recursion in extension functions sha1_query() or sha3_query(). [bugs:/info/2026-07-29T06:29:33Z|Bug 2026-07-29T06:29:33Z].
Change the ROLLBACK command so that pending statements to not block it. The pending statements instead return SQLITE_ABORT upon next access. Note: This causes separate shared-cache connections in read_uncommitted mode to abort as well.
Identify requirements text in the SQLITE_CONFIG_ documentation. Fix a typo (a duplicated word) in part of that documentation. Add some requirements marks for DETACH to the test scripts. No code changes.
Obtain the required shared-cache write-lock when executing "DELETE FROM tbl" statements. Fix for [1e1321ee98].
Fix a test case on CLI ".help" output due to the output changing because of check-in [1590b401ff0670b6].
Fix a bug in ".show". Adjust test cases for the new default mode.
Close database connections in a timely manner to fix test script problems on Windows.
Rename the ext/misc/analyze.c extension to ext/misc/diskused.c, to avoid confusion with the src/analyze.c file. The function is now called "diskused(X)" instead of "analyze(X)". The CLI command is renamed from ".dbstat" to ".diskused".
Adjust the changes to shell8.test from [5da9bf09cc00faf9] so that they work with older versions of TCL.
Back out the --compat option from the CLI.
Fix the sha1() extension function so that it interprets zero-length BLOBs as BLOBs and not as NULL. Also add a few test cases for that extension function, which was previously completely untested. [bugs:/info/2026-07-29T06:31:41Z|Bug 2026-07-29T06:31:41Z].
Add tests to prevent a regression of the short read problem discovered in version 3.2.2. (CVS 4428)
Add the sqlite3_rtree_query_callback() API to the RTree virtual table. (Cherrypick from the sessions branch.)
If a subquery is materialized due to an ORDER BY and that ordering is useful in helping to satisfy the ORDER BY or GROUP BY in the order query without doing an extra sort, then omit the extra sort.
Enhancements to skip-scan such that it is operable when a middle column of an index is skipped while the left-most column is constrained in the WHERE clause.
Add an ORDER BY to a test case for skip-scan to make the output consistent.
If a call to sqlite3_snapshot_open() fails because the requested snapshot no longer exists, return SQLITE_ERROR_SNAPSHOT instead of SQLITE_BUSY_SNAPSHOT.
Update a few test scripts so that they run on windows.
If SQLITE_USE_SEH is defined, handle structured-exceptions thrown by MSVC builds if the *-shm file mapping is accessed after it becomes invalid for some reason.
Fix an assert() that could fail within calls to sqlite3_snapshot_open() in SQLITE_ENABLE_SETLK_TIMEOUT builds.
Fix a test script error causing tests to fail in soak.test.
More test cases and requirements marks for pragmas.
The sorter enhancement at [bdc841de10fef65b] contains a bug where it might sort 64-bit integers in the wrong order due to the limited precision of double. Fixed here.
Avoid running test case sort2.2.3 under address-sanitizer. It runs out of memory on some 32-bit platforms.
Fix the sort4.test module so that the first two test cases are omitted when SQLite has been compiled using SQLITE_MAX_WORKER_THREADS=0.
Fix a few small test script issues affecting SQLITE_TEMP_STORE=3 builds.
Add the SQLITE_CONFIG_PMASZ start-time option.
Update test scripts speed1.test and speed1p.test so they may be run by testrunner.tcl.
Add speed-test scripts that also show EXPLAIN output. (CVS 5017)
Detect database file changes using a 128-bit segment of the file header that includes the change counter. Ticket #2303. (CVS 3844)
Rename a test procedure in 'speed3.test' to avoid a name collision.
Avoid running a couple of tests in crash8.test that depend on the presence of the journal file if running on an F2FS file-system that does not require a journal file.
Update speedtest.md to point out xdg-open on Linux.
Fix a help text typo in speedtest1.tcl, pointed out off-list by BrickViking.
Fix a harmless compiler warning in test/speedtest1.c.
Fix parsing of quoted instantiation arguments in the spellfix extension. [bugs:/info/2026-06-26T10:52:36Z|Bug 2026-06-26T10:52:36Z]
Adjustments to spellfix2.test so that it works reliably on mac.
Update spellfix1_scriptcode() to output 215 (latin) for pure numeric text.
Limit the size of input strings to the (disused) spellfix extension to avoid excessive runtime and integer overflows. [bugs:/forumpost/24a33e5d10|Bugs report 24a33e5d10].
Fix an issue with sqldiff reported by [forum:/info/9bd2155bdfae25a7|forum post 9bd2155bdfae25a7].
Small size and complexity reduction on the star-query heuristic. Improved comments for the star-query heuristic.
Add the "startup" test program designed to measure startup performance, and in particular schema parsing time.
There are two possible error messages from stat-9.1, depending on compile-time options. Adjust the test case to accept either one.
Add the stmtrand() extension function for use in testing.
Add a missing "finish_test" to the end of the stmtvtab1.test script.
Extend the pedantic enforcement of type to VIRTUAL columns.
Fix an issue in PRAGMA integrity_check associated reporting NULL values in a NOT NULL column of type ANY in a STRICT table.
Fix a problem that could occur when a scalar subquery had both a DISTINCT and OFFSET clause. First reported by [forum:41bd7af485 | forum post 41bd7af485].
Catch vector size mismatch problems during name resolution to avoid later problems.
Allow "substring()" as an alias for "substr()" for compatibility with other SQL engines.
When using an index on a CASE expression that may return a value with a subtype, avoid discarding any subtype.
Enhance the "swarmvtab" extension. See header comments in ext/misc/unionvtab.c for details.
Fix a problem in test file swarmvtab3.test causing occasional failures.
A unix VFS change replaces fsync() with fstat() when using SQLITE_NO_SYNC, so set PRAGMA synchronous=OFF in the sysfault-3 test to avoid erroneously causing errors in xSync.
Change the way pointers are passed between C code and Tcl test scripts. This allows tests to be run with Fil-C builds.
Various typo fixes reported by Daniel Dumitriu. No functional changes.
Throw an error if AUTOINCREMENT appears in a WITHOUT ROWID table. Updates to API documentation to discuss WITHOUT ROWID.
New build product "tclsqlite-ex.c" is the tclsqlite.c file with QRF added. This is now used whereever tclsqlite.c was used. Hence QRF is now in the testfixture and in the tclextension. The sqlite3 method is "format". That method is currently just a non-functional stub.
Fix some problems to do with temp-file databases and recovering from IO and SQLITE_FULL errors.
Add another test case to temptable3.test.
Add further test cases for temp triggers to this branch.
When rolling back a journal that contains a super-journal pointer, only attempt to unlink the super-journal if the filename looks like one that SQLite might have generated. This is to limit the extent to which SQLite can be caused to delete arbitrary files by supplying it with a crafted hot-journal. Bug [bugs:/info/2026-06-24T14:18:00Z | 2026-06-24T14:18:00Z].
Add the test/testloadext.c loadable extension to test the ability to use the latest APIs using the loadable extension mechanism.
Fix a problem introduced by [32c762bbb1] causing sessions module conflict handling to malfunction when used with a database handle configured with sqlite3_extended_result_codes(). Also ensure the "session_eec" permutation, which would have detected this, is run as part of release testing.
Add a new direct CLI testing script in test/modeA.clitest to demonstration that can be done. Rig this this to be run by test/shellB.test during normal testing.
Enable the thread test logic to work with the SQLITE_HAS_CODEC compile-time option.
Remove leftover "breakpoint" commands from test scripts. Also remove blank lines at the end of scripts. (CVS 6721)
Avoid running thread1.test or thread2.test if SQLITE_MUTEX_NOOP is defined.
Changes to the TCL extension and how it is built, suggested by Jan Nijtmans.
Bug-fixes to get the two threadtest C programs working again. (CVS 1756)
Fix some problems in test code detected by cppcheck.
Fix compilation of 'threadtest3' for some older versions of MSVC.
Add extra tests to threadtest4.c. Fix a benign data race accessing the text encoding using ENC(db).
Add the new threadtest5 test program for stressing multiple database connections in the same process hammering on a single database. Primarily designed to test memdb, but works on any database.
Update the wordcount.c test program and add a new script "time-wordcount.sh" for additional performance testing.
Extended the time-diff format so that it can have a 5-digit year. This enables time differences to span the full range of dates supported by SQLite. Also fix some inaccuracies in the computation of time differences and add new test cases.
Add some missing "finish_test" lines to the end of test scripts.
"make test" now passing.
All tests in "make test" now pass with Tcl9, except for about 198 cases where the error involves small differences in the rendering to floating point values.
Do not reuse function parameters in subsequent expressions since the function call might have triggered a text encoding change. Fix for ticket [2ea2425d34be].
Add an optimization that attempts to run a subquery as a coroutine rather than manifesting it into a temporary table.
Do correct affinity transformations on floating point values which have a decimal point at the beginning or end of the mantissa. Ticket [3998683a16a7076e08f5].
Always clear the temporary register cache after coding a subroutine.
Back out the change from [7fab1393c2b22b1f] that tries to convert invalid surrogate characters in UTF16 into the replacement character 0xfffd, as we find that this breaks some software.
Make sure that virtual WHERE-clause terms do not get transformed into real terms when processing set of OR-connected terms. Fix for ticket [4c86b126f22ad].
Enhance tests for ticket [4dd95f6943].
Fix comment in test.
Fix for [54844eea3f]: Do not create automatic indexes on correlated sub-queries.
Fix for ticket [5e10420e8d].
Candidate fix for ticket [6bfb98dfc0c]: Make sure invalid cursors drop all references to database pages prior to doing any insert or update.
Skip flattening if subquery has LIMIT and outer query is DISTINCT. Fix for ticket 752e1646fc.
Remove debugging pragmas accidently left in by a prior change.
Fix requirements marks so that they match documentation corrections.
Add a missing test that prevented double LEFT JOINs with transitive constraints from working correctly. Fix for ticket [868145d012].
Do not allow temporary registers to be in use across an OP_Yield within a co-routine. Fix for ticket [8c63ff0eca81a9132d8].
Add a test for ticket [91e2e8ba6f]. No changes to code.
Fix a missed optimization opportunity due to a typo in check-in [898bfa1afd8260ea]. Reported by [forum:/forumpost/2026-01-31T00:49:53z|forum post 2026-01-31T00:49:53z].
Add some more IN operator tests.
A couple more test cases.
When casting string values into numeric and the string has a prefix that looks like a number but total string is not a well-formed number, then take extra care that the result is either integer or real depending on what the prefix looks like. Fix for tickets [e8bedb2a184001] and [4c2d7639f076aa].
Test case and fix for the specific failure of ticket [b351d95f9cd5ef17e9d9dbae].
Adjust date/time functions so that they do a better job of keeping track of whether the current time is UTC or localtime, and no-op the 'utc' and 'localtime' modifiers accordingly. See [forum:/info/e7a939e074|forum post e7a939e074]. Also add the datedebug() function, available only under -DSQLITE_DEBUG, for improved visibility of the DateTime object during debugging and testing.
Before running each test script, make sure the FTS enhanced query syntax is disabled.
Do not abort running queries due to a CREATE INDEX statement. Allow them to run to completion before being reprepared. Fix for ticket [c694113e50321afdf9].
Update the OP_Move opcode to shift the pScopyFrom pointer of aliases when compiled with SQLITE_DEBUG. Ticket [d63523637517386191].
This is a cherry-pick of version [b5df5ac052].
Make sure the query optimizer for aggregate queries knows that expressions (x='a') and (x='A') are different. Ticket [fa7bf5ec94801e7e]
Fix the tkt-fc62af4523.test to work around non-randomness of the randomblob() function when in testing mode.
Fix a bug (ticket [fc7bd6358f59]) that caused incorrect query results in three way queries that involved comparing INTEGER and TEXT columns for equality.
Test suite fixes for builds that define OMIT symbols. (CVS 2962)
Modify the test cases in tkt1444.test that were failing. I am convinced that the test cases were incorrect. (CVS 3288)
Get tests working with SQLITE_OMIT_AUTOVACUUM=1. (CVS 3918)
Simplifications to the Expr object: Remove Expr.span completely and convert Expr.token into a char* Expr.zToken. Also simplify the Token object by removing the Token.dyn and Token.quoted fields. (CVS 6681)
Fix incorrect type conversions when copying from a table into itself. Ticket #1536. (CVS 2773)
Fixes for OMIT_SUBQUERY builds: Disable where clause OR->IN optimization. Include EXISTS keyword (for new CREATE TABLE syntax). Test file fixes. (CVS 2943)
Minor test file modifications for builds compiled with OMIT options. (CVS 3077)
Fixes for compilation/testing when the various OMIT macros are defined. (CVS 4423)
Consider explicit collate clauses when matching WHERE constraints to indices. Fix for #2391. (CVS 4040)
When expanding '*' in the result set of a SELECT, quote the expanded identifiers. Fix for #2450. (CVS 4111)
Enhance sqlite3_shutdown() so that it automatically invokes sqlite3_reset_auto_extension(). This is a harmless no-op if applications are already calling sqlite3_reset_auto_extension() prior to sqlite3_shutdown(). And it prevents possible memory corruption if they do not. So it works either way. Most of the changes are to the test cases. (CVS 6475)
Fix incorrect index cost assumptions that occur after an ANALYZE. Ticket #2643. (CVS 4424)
Fix compilation and testing when SQLITE_OMIT_TRIGGER is defined. Ticket #3786. (CVS 6464)
Bare identifiers in ORDER BY clauses bind more tightly to output column name, but identifiers in expressions bind more tightly to input column names. This is a compromise between SQL92 and SQL99 behavior and is what PostgreSQL and MS-SQL do. Ticket [f617ea3125e9c].
More test case changes so that shared-cache mode tests all work with normalized database names.
Add more test cases to prove that ticket #2920 does not exist in CVS HEAD. The problem was previously fixed by the changes to ticket #2686. Ticket #2920 is a duplicate of #2686. (CVS 4772)
Do not apply the query flattening optimization when the outer query is an aggregate and the inner query contains an ORDER BY clause. Ticket #2943. (CVS 4791)
The COMMIT command now works even if there are pending queries, as long as the pending queries are reading and not writing the database. (CVS 5864)
Make sure that when a connection is blocking on a RESERVED lock that it continues after the lock is released. Ticket #3093. (CVS 5078)
Fix compilation with OMIT_TRIGGER defined. Ticket [1ff6d29030e9757d052af0f394e56bea96b8b59b|1ff6d29030].
Additional test cases for nested subqueries in a WHERE clause. (CVS 5999)
Add a test script to verify that ticket #3419 stays fixed. (CVS 5771)
Additional refinements to Expr handling. Restore compression of trigger expressions. Change Expr.zToken to Expr.u.zToken and added Expr.u.iValue. Remove an unnecessary ExprDup from CHECK constraint processing. And so forth. (CVS 6682)
Expand table.* properly on a USING or a NATURAL join. Ticket #3522. (CVS 5979)
Convert the "~" and "NOT" operators to be two-address instructions. Ticket #3541. (CVS 6028)
Here is the test case to prove that ticket #3581 is fixed. (CVS 6174)
Change "PRAGMA disable_recursive_triggers" to "PRAGMA recursive_triggers". Also a fix for compiling with OMIT_TRIGGER defined.
Enhance the ANALYZE command so that it gathers statistics in the sqlite_stat1 table even for tables that are empty or have no indices.
Make sure a ROLLBACK that follows an incremental vacuum works. Ticket #3761. (CVS 6416)
If a rollback mode transaction reduces the size of the database file, avoid actually truncating the file until after the transaction has been committed (but before the db has been unlocked). This means pages that are removed from the database by truncating the file need not be journalled.
Do not attempt to walk a TokenOnly or SpanOnly expression tree node. Ticket #3791. (CVS 6469)
Suppress errors associated with TEMP triggers that reference objects in non-TEMP databases. This is a continuation of the fix for ticket #3810 shown in check-in [ba1afc040171810d] from [/timeline?c=trunk:200908061743|2009-08-06], based on a bug report in [forum:/forumpost/157dc791df|forum post 157dc791df]
Allow an index paired with a NOT NULL constraint to be used for sorting under the condition that the index be treated as a non-unique index.
Fix ALTER TABLE RENAME so that it correctly handles triggers that attach to the table using the name in a different case. Ticket [ae6794effd404].
Add the "colUsed" field to the sqlite3_index_info structure passed to virtual table xBestIndex methods. To indicate the subset of the virtual table columns that may be required by the current scan.
Make sure nested queries with USING clauses do not leak memory. Preliminary fix for ticket #3911. (CVS 6750)
Changes to various test scripts so that they pass on windows.
Improved technique for parsing the ON and USING clauses of a join is faster and uses less memory.
When flattening a SELECT query, do not discard collation sequences explicitly attached to expressions in the parent query. Fix for #3997. (CVS 6949)
Testing coverage enhancements. (CVS 5358)
Show the text of individual statements within a trigger, as they execute, as comments in the output from sqlite3_trace() and sqlite3_trace_v2().
Fix a problem causing the fts3 integrity-check to fail if run inside a transaction.
Add support for the sqlite3_txn_state() interface.
Fix minor problems surrounding transitive WHERE constraints and explicit COLLATE terms.
Insert #ifdefs that can optionally remove features at compiletime resulting in a database engine with a smaller footprint. (CVS 2034)
Fix a datatype in trigger6.test that changed due to the previous check-in. (CVS 2454)
Changes to support recursive triggers.
Additional coverage testing in the new name resolver module. (CVS 5608)
Fix a harmless "jump or move depends on uninitialised value" warning that could occur when using a virtual table as the RHS of an outer join within a trigger.
Remove unnecessary whitespace from testcase result strings.
Fix JSON functions so that they work correctly under PRAGMA trusted_schema. [forum:/forumpost/c88a671ad083d153|Forum thread c88a671ad083d153].
Updates so that "threadtest3[.exe]" can be built for windows with MSVC.
Further enhancements to threadtest3 stress tests.
Fix a tsan error that could occur when using shared-cache mode.
Remove the sqlite3BtreeFactor() wrapper routine. All modules now call sqlite3BtreeOpen() directly.
Fix a problem causing the affinity of sub-select row-value elements to be ignored in some contextes.
In the name resolver when SQLITE_ALLOW_ROWID_IN_INDEX is enabled, if there are multiple views that might resolve to the "rowid" but only one real table, then use that one real table and ignore the views.
Avoid coding unindexed WHERE constraints if an equivalent transitive term has already been coded by an outer loop.
When flattening UNION ALL subqueries into a join query, ensure that separate cursor numbers are used for each segment of the newly flattened query.
Fix a NULL pointer dereference that could occur in the unionvtab virtual table if the configuration SQL returned an SQL NULL value in place of a table name. Bug [bugs:/info/2026-06-23T05:32:49Z | 2026-06-23T05:32:49Z].
Do not allow rowid in a UNIQUE or PRIMARY KEY constraint. (This restores the same behavior exhibited by all prior releases.)
Fix the BETWEEN operator so that it propagates the EP_Subquery, EP_Collate, and EP_HasFunc flags in the expression tree, as it ought. Fix for the problem reported at [forum:/forumpost/2026-04-21T19:10:55Z|forum post 2026-04-21T19:10:55Z] and probably a bunch of other problems too. This has been incorrect for a long time.
Make sure cursors are opened on all indexes for an UPDATE OR REPLACE regardless of whether or not the indexes are partial or contain columns that might need to be updated.
Make it an error to repeat the target object/alias of an UPDATE statement in its FROM clause.
Fix a faulty assert() statement in sqlite3ExprListDup(). This is a continuation of the fix at [59812e7ef705226c].
Fix the assert() that attempts to verify that the table-reference to index-reference translator finds all required translations. [forum:/forumpost/929168fdd6|Forum post 929168fdd6].
Avoid performing aggregate processing more than once for a single expression. [forum:/info/36ff78b2a3|Forum post 36ff78b2a3].
Add function format() as an alias for printf(), for compatibility with other systems.
Fix the table name aliasing on INSERT so that it occurs before the column list rather than afterwards, just as it does for PostgreSQL. Add table name aliasing to UPDATE and DELETE.
A few more tests for upsert.
Fix a problem sometimes causing an UPSERT to incorrectly convert an excluded.* column from type REAL to INT in cases where doing so does not cause data loss. Bug [bugs:/info/2026-06-15T09:08:12Z | 2026-06-15T09:08:12Z].
Add extra tests to check the result of including a %00 escape in a URI when ENABLE_URI_00_ERROR is defined.
Fix VACUUM so that it works even when ATTACH_WRITE is disabled.
Avoid loading large intkey rows when VACUUMing, even if the page-size is changing.
Fix vacuum3.test so that it works with SQLITE_OMIT_ALTERTABLE builds.
Attempt to reduce the memory used by VALUES clauses in as many statements as possible, not just INSERT. This branch still has problems.
Limit VIEW recursion depth to SQLITE_LIMIT_EXPR_DEPTH to prevent static overflow in malicious schemas with tens of thousands of levels of recursive views. [bugs:/info/2026-06-16T04:21:51Z|Bug 2026-06-16T04:21:51Z]
Ensure that objects within view definitions are not incorrectly resolved to CTEs that are part of the statement using the view.
Bug fix in the vt02.c test virtual table.
Fix the test/vt100-a.sql script to use .testcase and .check.
Avoid accessing the sqlite3_module.xShadowName field if (sqlite3_module.iVersion<3).
Test case for writing to a WITHOUT ROWID virtual table. The TCLVAR virtual table is modified to add a "fullname" column which is the primary key, and to accept update operations against the primary key.
Add support for the extra parameter on the sqlite3_set_authorizer() callback and support for failing an ATTACH with an authentication-required database using bad credentials. The extension is now feature complete, but much testing and bug-fixing remains.
New requirement marks.
Handle the case where the estimated cost of a virtual table scan is larger than SQLITE_BIG_DBL. Ticket #2253. (CVS 3670)
Ensure sqlite3_finalize() can be called from within the xDisconnect() method of virtual tables. (CVS 3845)
Add test cases to prove that ticket #3082 has been fixed. (CVS 5048)
Fix typos in 'vtabF.test' file. No changes to code.
Fix vtabH.test so that it works on windows even if there are files that begin with "$" in the root directory.
Fix UPDATE FROM statements on virtual tables that are declared WITHOUT ROWID.
Improved the error message that results when a schema parse fails after ALTER TABLE ADD COLUMN.
Add extra tests for the error messages generated by sqlite3_declare_vtab() when passed something other than a well-formed CREATE TABLE statement.
Fix a failing assert() in sqlite3ResetAllSchemasOfConnection().
Bring sqlite3_vtab_distinct() up to spec so that it works as described in the documentation.
Fix a problem causing the sqlite_master entry corresponding to a virtual table to be removed by a DROP TABLE even if the call to the vtabs xDestroy() method failed.
Update stale evidence marks on sqlite3_vtab_rhs_value() test cases.
Back out minor changes not required by this branch.
Further tweaks to the wal7.test test case.
Update a couple of test scripts so that they work in auto-vacuum mode.
On Windows, make sure the current directory value used by the test suite is 'normalized' to what the parent command shell sees. Also, clean the test directories used by the quota2.test file.
Update walcksum.test so that it works with SQLITE_DEFAULT_AUTOVACUUM=1 builds.
Update walcrash.test to ensure that, during a particular test, enough data is written to cause SQLite to sync the wal file 14 times.
Fix duplicate test names in 'walfault.test'.
Avoid attempting to delete a file while it is still open in walfault2.test.
Add a version number to the wal-index header. If SQLite encounters a version number in either the wal or wal-index files that it does not understand, the operation is abandoned and SQLITE_CANTOPEN returned.
It turns out that pagerExclusiveLock() can be called with the lock state already set to RESERVED if the SQLITE_FCNTL_PERSIST_WAL setting is set and a specific sequence of multiple journal mode changes occur. Enhance pagerExclusiveLock() to deal with this. [forum:/forumpost/8130545bc6|Forum post 8130545bc6]
Fix a couple of test scripts to match the new wal recovery behaviour on this branch.
In wal mode, if a "BEGIN EXCLUSIVE" command (or any other command that upgrades from no transaction directly to a write transaction) hits an SQLITE_BUSY_SNAPSHOT error, change the error code to SQLITE_BUSY to indicate to the caller that the condition may be transient.
Uninstall faultsim at the end of the walrestart.test script.
Fix the ability to read read-only WAL-mode database when -shm is present, ([00ec95fcd02bb415|check-in 00ec95fcd02bb415]) so that it works for the case of 64K page size.
Get read-only SHM file tests passing on Win32.
Have sqlite3_setlk_timeout() take the database handle mutex. This fixes an assert() failure that could occur if sqlite3_setlk_timeout() were called on a threadsafe handle.
Fix test script errors in walsetlk3.test. Tests still don't all pass.
Fix os_win.c so that SQLITE_ENABLE_SETLK_TIMEOUT=2 builds work on windows.
Update the test/walthread.test testing script so that it uses a random database name.
Improved optimization of "expr OR TRUE" and "expr OR FALSE". [bugs:/info/2026-07-25T08:36:25Z|Bug 2026-07-25T08:36:25Z].
Fix an incorrect assert() in check-in [984c9b181801c1de]
Improvements to the query planner to address the inefficiency described by [forum/forumpost/2568d1f6e6|forum post 2568d1f6e6].
Additional test cases for comparisons against NULL in the WHERE clause and elsewhere in a SELECT. (CVS 4051)
Make sure the ON clause of a LEFT JOIN does not cause an index to be used to speed access to a table to the left of the join. Ticket [ebdbadade5]
Fix a test case whose value changes under the no_optimization permutation due to the recent change to add the ability for SQLITE_TESTCTRL_OPTIMIZATION to disable one-pass.
Add the "sorter-reference" optimization, allowing SQLite to be configured so that some required values may be loaded from the database after external sorting occurs for SELECT statements with ORDER BY clauses that are not satisfied by database indexes.
Show LEFT and RIGHT JOIN processing in the EXPLAIN QUERY PLAN output.
Disable the OP_SeekScan opcode of the in-scan-vs-index optimization when in PRAGMA reverse_unordered_selects mode, as the OP_SeekScan only works with forwards scans. Thanks to OSSFuzz for pointing out the problem to us.
Tweak to the new whereB.test file to make it more consistent.
Simplified implementation of indexing with the IS operator.
In the OP_Column opcode, if the cursor is marked NullRow (due to being the right table of a LEFT JOIN that does not match) and the cursor is the table cursor for an OR-optimization with a covering index, then do not substitute the covering index cursor, since the covering index cursor does not have the NullRow flag set. Ticket [aa4378693018aa99]
Also make sure an index that is a proper subset of some other index has a higher cost than that other index. Add test cases.
The optimization at [8bdda827a3d26800] is incorrect for the case where one of the two expressions has been commuted such that the collating sequence has changed. This check-in fixes the problem. Problem reported by [forum:/forumpost/2026-01-16T11:35:28Z|forum post 2026-01-16T11:35:28Z].
Fix an obscure problem allowing the propagate-constants optimization to improperly substitute a column of a sub-query with NONE affinity.
Add new test file whereM.test. Containing tests for the change on this branch.
Add a heuristic in between the two solver() passes of the query planner that tries to prevent a very slow query plan in cases where the output row count estimate is imprecise.
Add extra test case for OOM handling in where.c.
Add further tests for the code on this branch.
Fix incorrect RETURNING test cases in wherelimit.test
Omit bogus tests accidentally added by the privious commit.
Better optimize queries that use parameters in the LIMIT clause.
Test cases for covering indexes on wide tables.
The win32lock and win32longpath tests don't work on Cygwin
Remove #ifdefs intended to make SQLite compatible with Windows RT. WinRT was short-lived and has been discontinued for a long time.
Merge trunk. Some additional test-fixes for Cygwin
Improve performance of window function queries that use "BETWEEN :x FOLLOWING AND :y FOLLOWING" where :y is a very large number.
Do not mistake constant integers in a PARTITION BY expression for references to ORDER BY style references to values returned by the SELECT statement.
Implement the EXCLUDE clause for window frames.
Fix handling of window functions in aggregate queries that have no GROUP BY clause. Also remove a faulty assert causing the error reported in [618156e3].
Support some "ROWS BETWEEN N PRECEDING AND M FOLLOWING" window functions without caching entire partitions.
Fix problems with window frames that use ORDER BY ... NULLS LAST etc.
Fix a problem with window functions min() and max() when used with a FILTER clause. Forum post [forum:/forumpost/e9126d554a | e9126d554a].
Back out the change at [47cd634c98b502d4] which was incorrect. Add a test case so that we don't accidently back out that change again.
Fix the window-function variant of the json_group_object() function so that it correctly handles NULL entries. [bugs:/forumpost/0de87b23b3|Bug report 0de87b23b3].
Fix windowC tests to specify little-endian or big-endian UTF16, for cross-platform portability. [forum post 559b84a5c6|forum:/forumpost/559b84a5c6]
Fix a problem with flattening and window functions causing an "IS <column>" to be transformed to "IS TRUE" or "IS FALSE" when <column> is a view or sub-select expression that is the literal value "TRUE" or "FALSE".
Have window functions sum(), total() and avg() correctly handle the obscure case where integer overflow occurs as part of the same step that adds the first real value to the running total.
Fix error handling for the case where a window function is passed the wrong number of arguments.
Add extra tests for the group_concat() fix on this branch.
Improved detection of CTEs being misused as table-valued functions. Remove an incorrect assert() from check-in [716782abe939083b].
Fix a name resolution issue with CTEs.
The view-scan optimization was added to enhance the performance of one specific query, but it causes performance regressions on a host of others. Disable it (at least temporarily) in order to try to find an alternative way of fixing the one specific query that it was created to fix - an alternative way that does not cause performance problems for other unrelated queries.
Do not allow parameters or schema references inside of WITH clause of triggers and views. This fixes a bug discovered by OSSFuzz and present since common-table-expressions were first added in 2014-02-03.
Improve comments. Move a variable outside of a loop.
Enhance a comment on a test case to add recent context.
Many new test cases added, that mostly work. Currently 18 errors in without_rowid3.test. Also there is a hack marked by a /*FIXME*/ comment on at fkey.c:547 that needs fixing.
Avoid returning SQLITE_ERROR_RETRY if collation sequences associated with the table's PK cannot be found when creating an index. Possible fix for [forum:aa61ab56ad | forum post aa61ab56ad].
Add the --upsert option to the wordcount test program.
Fix a potential UAF bug in the zipfile extension. [bugs:/info/2026-06-03T10:58:51Z|Bug 2026-06-03T10:58:51Z].
Fix a possible 9-byte buffer overread in the zipfile extension hit when processing a corrupt zip file. Forum post [forum:/forumpost/721a05d2c5 | 721a05d2c5].
Fix a test case in zipfilefault.test so that it only runs if JSON1 is available.