stephan [Wed, 22 Nov 2023 17:13:27 +0000 (17:13 +0000)]
Correct the URL for loading sqlite3-worker1-bundler-friendly.mjs from sqlite3-worker1-promiser-bundler-friendly.js, so that the promiser can be used in bundler-using environments. Problem reported via email.
larrybr [Tue, 21 Nov 2023 18:46:17 +0000 (18:46 +0000)]
Pickup minor stylistic changes related to console I/O and, for Windows builds, get fact of UTF-16 translation into the sign-on banner. (a straight cherry-pick)
drh [Thu, 9 Nov 2023 17:42:46 +0000 (17:42 +0000)]
Add the SQLITE_RESULT_SUBTYPE flag for application-defined functions. Add
the -DSQLITE_STRICT_SUBTYPE=1 compile-time option that raises an error if
any function invokes sqlite3_result_subtype() without the SQLITE_RESULT_SUBTYPE
flag. SQLITE_RESULT_SUBTYPE prevents an indexed value of that function from
being used to replace an equivalent expression, since the indexed expression
does not carry the subtype.
drh [Tue, 7 Nov 2023 19:15:55 +0000 (19:15 +0000)]
Update the documentation to the sqlite3_set_auxdata() and sqlite3_get_auxdata()
routines to make it clear that they do not work as one might expect when they
are called during query planning, instead of during query execution. The JSON
routines misuse those interfaces, so add a special flag to JSON routines that
prevents them from being invoked during query planning.
drh [Mon, 6 Nov 2023 19:08:46 +0000 (19:08 +0000)]
Update the srctree-check.tcl script and child script so that they can be run
on a read-only source tree and so that if any inconsistencies are found, the
script returns a non-zero exit code and thus halts the build.
drh [Mon, 6 Nov 2023 19:01:25 +0000 (19:01 +0000)]
Fix an fts5 problem where a transaction consisting of (a) a DELETE on rowid X, (b) a prefix query, and (c) an INSERT on rowid X, could corrupt the index.
drh [Mon, 30 Oct 2023 19:03:17 +0000 (19:03 +0000)]
Add a cast to i64 for an integer in an sqlite3OsWrite() offset
calculation. The cast is not strictly necessary, but it helps human readers
see that the code is correct.
drh [Mon, 30 Oct 2023 12:09:48 +0000 (12:09 +0000)]
With SQLITE_ENABLE_BLOCK_ATOMIC_WRITE enabled, if a transaction is committing
and there is a new freelist page at the end of the database file which would
cause the database file size to grow, ensure that page is written and the
file size grows before the block-atomic-write commits. Fix for the
problem identified by [forum:/forumpost/3bd8d497b2|forum post 3bd8d497b2]
larrybr [Sun, 29 Oct 2023 16:26:12 +0000 (16:26 +0000)]
Properly close a handle. Use a putatively effective runtime test for UTF-8 console I/O capability. (This makes the version test useful mainly for avoiding a warning that UTF-8 console I/O could not be setup.)
larrybr [Sun, 29 Oct 2023 00:24:22 +0000 (00:24 +0000)]
Condition default UTF-8 console I/O for Windows builds on OS version 10 or more. This is to accomodate an IsValidCodePage() API which may happily report CP_UTF8 as a valid code page when the stock console cannot, in fact, do UTF-8 I/O.
drh [Sat, 28 Oct 2023 11:53:14 +0000 (11:53 +0000)]
Update documentation for sqlite3_errmsg() to try to make it clear that if
the schema of a database contains table names or similar with invalid UTF,
then the error message generated by SQLite might also contain invalid UTF.
No changes to code.
drh [Sat, 28 Oct 2023 11:40:33 +0000 (11:40 +0000)]
Since SQLite considers NaN to be like NULL and NULL sorts before any integer,
make sure the sqlite3IntFloatCompare() routine reports that the integer
argument is larger if the floating-point argument is NaN.
stephan [Sat, 28 Oct 2023 03:54:28 +0000 (03:54 +0000)]
Remove the SQLITE_MAX_ALLOCATION_SIZE flag (set to 536mb) from the WASM and JNI builds because it can unduly limit db exports via sqlite3_serialize(), as reported in [forum:75524f7342c1ba45|forum post 75524f7342c1ba45]. It now defaults to whatever sqlite3.c uses, which is currently just shy of 2gb.
drh [Fri, 27 Oct 2023 18:16:15 +0000 (18:16 +0000)]
Disable two rtree test cases for Linux-i686. We do not have that platform
available for testing. The test cases work on all other 64-bit and 32-bit
platforms that we have at hand. So there is no way for us to debug this
problem. Better to disable the test.
[forum:/forumpost/ffcbf789b5386573|forum post ffcbf789b5386573].
larrybr [Fri, 27 Oct 2023 13:59:05 +0000 (13:59 +0000)]
Cleanup shell.c comments. Hide -utf8 option, as it is undocumented and accepted only for backward compatibility. No functional changes except for -help content.
drh [Fri, 27 Oct 2023 10:49:17 +0000 (10:49 +0000)]
Back out [2904fcbeebba9189], mostly. The page bitmap is needed even for a
partial integrity_check in order to avoid an infinite loops while walking the
database.
drh [Thu, 26 Oct 2023 17:30:54 +0000 (17:30 +0000)]
Enhance the "tool-zip" makefile target on Windows so that it uses more
universally available commands to build the ZIP archive. Fix other minor
issues with that makefile target at the same time.
dan [Thu, 26 Oct 2023 16:05:57 +0000 (16:05 +0000)]
Handle the case where a virtual table xBestIndex method called while coding a trigger fired by a top-level statement with a RETURNING clause prepares a statement that also contains a RETURNING clause.
drh [Thu, 26 Oct 2023 12:59:41 +0000 (12:59 +0000)]
Deal with the case of a reentrant INSERT on a virtual table where the
outer INSERT has a RETURNING clause but the inner does not.
dbsqlfuzz 3ac9a1e33f676254e02c0f297263b0a7aeb0c1a5.
drh [Wed, 25 Oct 2023 12:58:06 +0000 (12:58 +0000)]
Fix the amalgamation generator so that when it is reporting the Fossil
version number in the header comment of the amalgamation, it does not
elide the first hex digit of the version hash.
drh [Wed, 25 Oct 2023 10:37:11 +0000 (10:37 +0000)]
Enhance the new xIntegrity method of the sqlite3_module object with new
parameters that provide the name of the table being checked and
a flag to indicate a "quick_check". Based on feedback in
[forum:/forumpost/965c0d02ea|forum post 965c0d02ea].
dan [Tue, 24 Oct 2023 16:06:56 +0000 (16:06 +0000)]
Fix a problem with the fts5 highlight() and snippet() functions when used with tokenizers like "trigram" that output overlapping tokens. Forum post [forum:/forumpost/63735293ec|63735293ec].
dan [Tue, 24 Oct 2023 15:53:02 +0000 (15:53 +0000)]
Fix a problem with the fts5 highlight() and snippet() functions when used with tokenizers like "trigram" that output overlapping tokens. Forum post [forum:/forumpost/63735293ec|63735293ec].