]> git.ipfire.org Git - thirdparty/sqlite.git/log
thirdparty/sqlite.git
10 months agoADd SQLITE_USE_ONLY_WIN32 to the Default configuration for testing on new-win32-test-config
drh [Tue, 3 Sep 2024 17:01:07 +0000 (17:01 +0000)] 
ADd SQLITE_USE_ONLY_WIN32 to the Default configuration for testing on
Windows.  Take it off of Stdcall.

FossilOrigin-Name: 8ace3f15e4f7e8249bf4cf558ceecdf67792bb7801529ef86b4d36363bb8ff8c

10 months agoEnhance the "errors" command in testrunner.tcl so that it accepts the
drh [Tue, 3 Sep 2024 16:04:34 +0000 (16:04 +0000)] 
Enhance the "errors" command in testrunner.tcl so that it accepts the
"-s" or "--summary" argument to see a list of failed jobs, and so that
an additional argument is a GLOB pattern that restricts the output to
jobs whose names match that pattern.

FossilOrigin-Name: dcbebe30f594a99e23b5ccd8d199b92118204a3e52e75c78d98c394601252e81

10 months agoFix ext/consio so that it works correctly with SQLITE_USE_ONLY_WIN32.
drh [Tue, 3 Sep 2024 14:15:57 +0000 (14:15 +0000)] 
Fix ext/consio so that it works correctly with SQLITE_USE_ONLY_WIN32.

FossilOrigin-Name: efc6f3d7e92a25f440fb8d392daf325af5ca7dca104a5bb4bd59f7df93af53b0

10 months agoIn testrunner.tcl, compile the Windows Default configuration using
drh [Tue, 3 Sep 2024 14:00:36 +0000 (14:00 +0000)] 
In testrunner.tcl, compile the Windows Default configuration using
SQLITE_ENABLE_STMT_SCANSTATUS.

FossilOrigin-Name: 49e8b1635f29d9fd0dc2ef6e312fd4129f2283f68e9423d95ff9b55077688ad7

10 months agoFix harmless compiler warnings in the percentile extension.
drh [Tue, 3 Sep 2024 12:41:21 +0000 (12:41 +0000)] 
Fix harmless compiler warnings in the percentile extension.

FossilOrigin-Name: c5557f281c6294b6db6682349d245feac7c6ce7f4f61356f486afdf186c566c4

10 months agoIn testrunner.tcl, allow setting njob to zero, which causes no new jobs
drh [Tue, 3 Sep 2024 10:53:32 +0000 (10:53 +0000)] 
In testrunner.tcl, allow setting njob to zero, which causes no new jobs
to be launched and for the process to shut down once all current jobs are
completed.

FossilOrigin-Name: 0ef65fd4ba17def4c13986365b3af300c4024725af4bc314845d1af8be568ab4

10 months agoCause cfGets() (under SQLITE_USE_ONLY_WIN32) to better emulate fgets().
larrybr [Tue, 3 Sep 2024 02:09:13 +0000 (02:09 +0000)] 
Cause cfGets() (under SQLITE_USE_ONLY_WIN32) to better emulate fgets().

FossilOrigin-Name: 2d783524d1671d988ebb1b21c83de99c9f335963b6c20cf4df612f58c13da913

10 months agoFix possible NULL pointer dereference following OOM in the new error reporting
drh [Mon, 2 Sep 2024 21:59:31 +0000 (21:59 +0000)] 
Fix possible NULL pointer dereference following OOM in the new error reporting
logic of the percentile extension.

FossilOrigin-Name: 7891a266c4425722ae8b9231397ef9e42e2432be9e6b70632dfaf9ff15300d2c

10 months agoFix a technically undefined signed integer overflow in fts5.
dan [Mon, 2 Sep 2024 18:41:59 +0000 (18:41 +0000)] 
Fix a technically undefined signed integer overflow in fts5.

FossilOrigin-Name: e6bec37ea1ca51e1d048941ce4c5211d8fc5c5e3556a1441f9c79b036843f9e3

10 months agoMake the percential extension easier to incorporate as a built-in on Windows
drh [Mon, 2 Sep 2024 17:27:10 +0000 (17:27 +0000)] 
Make the percential extension easier to incorporate as a built-in on Windows
applications.

FossilOrigin-Name: 831e2be4117dc7f5113f66d3e484ca34e4405444ac7b0def12ee9a00608d40da

10 months agoRemove some debug/test code from percentile. Make the extension easier to
drh [Mon, 2 Sep 2024 14:46:56 +0000 (14:46 +0000)] 
Remove some debug/test code from percentile.  Make the extension easier to
statically link.

FossilOrigin-Name: 6e5f146e274b210749dd8923a2da56905eb098b5a66699ff9130e3e51b1ff662

10 months agoEnhance the percentile extension to support percentile_cont() and
drh [Mon, 2 Sep 2024 12:07:37 +0000 (12:07 +0000)] 
Enhance the percentile extension to support percentile_cont() and
percentile_disc().  Add support for ordered-set aggregate notation in
the parser when compiling with SQLITE_ENABLE_ORDERED_SET_AGGREGATES.  A
new function property SQLITE_SELFORDER1 must appear on any aggregate function
that wants to take advantage of the ordered-set aggregate notation.

FossilOrigin-Name: 557bd245ef24af15da1374762bbeb9b8b0241da06e604efdf00d567a9ed09216

10 months agoImproved error messages on percentile functions. More tests cases for ordered-set-agg
drh [Mon, 2 Sep 2024 11:17:04 +0000 (11:17 +0000)] 
Improved error messages on percentile functions.  More tests cases for
percentile and for ordered-set aggregates.

FossilOrigin-Name: e1bca168e70335fa2f9537632fd16e374c566a564fab4974c0b8f61cb63d08ce

10 months agoChange the name of the enabling compile-time macro to
drh [Mon, 2 Sep 2024 09:40:37 +0000 (09:40 +0000)] 
Change the name of the enabling compile-time macro to
SQLITE_ENABLE_ORDERED_SET_AGGREGATES.

FossilOrigin-Name: 3b1cdddf8339cc339ec74cd8be2bfa42e62b500048a444eb9e5d9817bc4702ae

10 months agoMore internal documentation improvements.
drh [Sun, 1 Sep 2024 23:56:14 +0000 (23:56 +0000)] 
More internal documentation improvements.

FossilOrigin-Name: 8b91b74931c36e1955ef933a07d8ec40c8b54c882efe7084d179168867c5244f

10 months agoImproved documentation of recent enhancements to the percentile extension.
drh [Sun, 1 Sep 2024 23:47:20 +0000 (23:47 +0000)] 
Improved documentation of recent enhancements to the percentile extension.

FossilOrigin-Name: 51e7b4c9cf19a5986432a76c5fd30cef715c170a403d7b4304a8c5888c445a91

10 months agoThe WITHIN GROUP (ORDER BY ...) syntax is now a compile-time option:
drh [Sun, 1 Sep 2024 23:27:34 +0000 (23:27 +0000)] 
The WITHIN GROUP (ORDER BY ...) syntax is now a compile-time option:
SQLITE_ENABLE_ORDERED_SET_FUNCS.  There is no increment in the code size
if the option is omitted.

FossilOrigin-Name: c9367e2532d653738af27c4d92810eb648a9e12f72d7223017c87cb0dddc6804

10 months agoImplement percentile_cont() and percentile_disc().
drh [Sun, 1 Sep 2024 20:24:24 +0000 (20:24 +0000)] 
Implement percentile_cont() and percentile_disc().

FossilOrigin-Name: b1a93f67d6b21df6fe3247c9333fead61dd425574f66ea3eb06b80c2b06f616a

10 months agoNo prepare-time penality for ordered-set aggregates for applications that
drh [Sun, 1 Sep 2024 19:19:26 +0000 (19:19 +0000)] 
No prepare-time penality for ordered-set aggregates for applications that
do not use them.

FossilOrigin-Name: e070c16d2183312e416ff6af770346041e4d3836c4db2c9ea6049f63fb0eaa07

10 months agoMerge fixes from trunk into the ordere-set-agg branch.
drh [Sun, 1 Sep 2024 18:57:52 +0000 (18:57 +0000)] 
Merge fixes from trunk into the ordere-set-agg branch.

FossilOrigin-Name: 7528ddcfdf155116353266e00e6408c526e29f04cb00ca2d9e84b105329b17c0

10 months agoImproved sort function in the percentile extension.
drh [Sun, 1 Sep 2024 18:54:31 +0000 (18:54 +0000)] 
Improved sort function in the percentile extension.

FossilOrigin-Name: 9f84e8d59bcda642e732565e840f6a880a01b2fc65af2651248f6a8a6e1cb65a

10 months agoFix to the quicksort algorithm in the percentile extension.
drh [Sun, 1 Sep 2024 10:52:20 +0000 (10:52 +0000)] 
Fix to the quicksort algorithm in the percentile extension.

FossilOrigin-Name: 54313f74b24c46f1afa1ff082ef569fa46938527095be358015e7047e17702ac

10 months agoAdd error checking: Do not allow functions other than those in the
drh [Sat, 31 Aug 2024 22:22:24 +0000 (22:22 +0000)] 
Add error checking: Do not allow functions other than those in the
percentile extension to use the ordered-set aggregate notation.

FossilOrigin-Name: 317d901429303340290334dbe7680a36339df0a50b586e3f71b6c5e5eba6d411

10 months agoDemonstration of how ordered-set aggregates might be parsed and integrated
drh [Sat, 31 Aug 2024 20:09:37 +0000 (20:09 +0000)] 
Demonstration of how ordered-set aggregates might be parsed and integrated
into the existing parse tree, should we decide to support them.

FossilOrigin-Name: ef9777890001ba0122d3add799795e118fd87243f42731ab84d4748b67605647

10 months agoInclude percentile() and merge() in the fuzzcheck test utility.
drh [Sat, 31 Aug 2024 19:24:17 +0000 (19:24 +0000)] 
Include percentile() and merge() in the fuzzcheck test utility.

FossilOrigin-Name: d1d0942a947803d45a1fd9068f3518cf412178b6b9bafcb82db44c52d5820c11

10 months agoOmit the percentile_cont() function added by [095c22e62248f8ef] (and not yet
drh [Sat, 31 Aug 2024 18:35:10 +0000 (18:35 +0000)] 
Omit the percentile_cont() function added by [095c22e62248f8ef] (and not yet
released) since its usage conflicts with the PG percentile_cont() function.

FossilOrigin-Name: 3fe0a852978f3f1218e37a58f0d3b54016d4116a3301aa32efa7c4c12c767755

10 months agoAllow percentile() and median() to act as window functions.
drh [Sat, 31 Aug 2024 18:08:31 +0000 (18:08 +0000)] 
Allow percentile() and median() to act as window functions.

FossilOrigin-Name: 94cf96af8fee55449080655bddf81cbf5c078a02d7bb5dd7e4903b36f83a8c07

10 months agoStill more test cases. percentile-window
drh [Sat, 31 Aug 2024 17:50:06 +0000 (17:50 +0000)] 
Still more test cases.

FossilOrigin-Name: f09904608195dac38172b0dd4dcab3190f33c116d468beff27f913a7433b400e

10 months agoAdd more test cases.
drh [Sat, 31 Aug 2024 17:27:55 +0000 (17:27 +0000)] 
Add more test cases.

FossilOrigin-Name: 0d0e5456793b4bef673ebc7fcc1c393a6d3c817363d948ddfe06d60eab56dc24

10 months agoAvoid unnecessary sort operations when running one of the percentile
drh [Sat, 31 Aug 2024 16:55:14 +0000 (16:55 +0000)] 
Avoid unnecessary sort operations when running one of the percentile
aggregates as a window function.

FossilOrigin-Name: 5d311536211eb1e3c887ceb7e6516d3900e6eebbccc8c445dd43cdd556182728

10 months agoTest cases added.
drh [Sat, 31 Aug 2024 15:02:07 +0000 (15:02 +0000)] 
Test cases added.

FossilOrigin-Name: 25e68229843cc84978955817285550085d1306ba4ce3b0517dd00e5d05b9ae0a

10 months agoEnhance the percentile() and median() extension functions so that they can be
drh [Sat, 31 Aug 2024 14:31:17 +0000 (14:31 +0000)] 
Enhance the percentile() and median() extension functions so that they can be
window functions.

FossilOrigin-Name: 4d0e3df4b9c609755977b8a462126242d2be1310c0122a8d4ba76d98d32a7230

10 months agoDo not fail the omittest if ICU libraries are not installed.
drh [Fri, 30 Aug 2024 17:33:25 +0000 (17:33 +0000)] 
Do not fail the omittest if ICU libraries are not installed.

FossilOrigin-Name: ddc55efd2d59df3f20743b0533550436da945453c069025a3f871d28d40e13d4

10 months agoNew makefile target: "tidy". The "tidy" target removes all build products
drh [Fri, 30 Aug 2024 16:51:41 +0000 (16:51 +0000)] 
New makefile target: "tidy".  The "tidy" target removes all build products
be leaves behind test results.  The "clean" target has been enhanced to do a
better job.  The tool/omittest.tcl script is rewritten to work on the
configure-generated Makefile and to require no arguments.

FossilOrigin-Name: e48add02695a41b26a04e7942b5333e2bf4dc5598e363367aea3a4690982667d

10 months agoA couple of #defines so that the build work with SQLITE_OMIT_FLOATING_POINT. makefile-improvements
drh [Fri, 30 Aug 2024 16:43:36 +0000 (16:43 +0000)] 
A couple of #defines so that the build work with SQLITE_OMIT_FLOATING_POINT.

FossilOrigin-Name: be768f80c703ac1645251ccbac83e07b3ea4cc231c8ea7e66374a4f78361f10b

10 months agoRework the tool/omittest.tcl script so that it works with the
drh [Fri, 30 Aug 2024 16:24:49 +0000 (16:24 +0000)] 
Rework the tool/omittest.tcl script so that it works with the
configure-generated Makefile, and requires no arguments.
Update the configure-generated Makefile with a new "tidy" target which
is like "clean" except that is preserves test logs.  Use "make tidy" to
force everything to be recompiled from scratch without destroying logs.

FossilOrigin-Name: 99491df19d68df1f0515bd5ec9240ef3dd6e0fa38a6c837a38a16a873f8e2cbb

10 months agoImprovements to "make clean" on unix.
drh [Fri, 30 Aug 2024 12:10:28 +0000 (12:10 +0000)] 
Improvements to "make clean" on unix.

FossilOrigin-Name: a1d775f07528192b09566ff1546b067ffbee0db5812e424e6b7f3cc33a67dc83

10 months agoIn the testrunner.tcl status report, try to provide a rough estimate of
drh [Fri, 30 Aug 2024 01:11:19 +0000 (01:11 +0000)] 
In the testrunner.tcl status report, try to provide a rough estimate of
the time remaining.

FossilOrigin-Name: 90bc616d20e8c247691c45de2a28d41c1632b21152dc34253eefc179a90ab31f

10 months agoSync the autoconf/Makefile.msc with the main ./Makefile.msc
drh [Thu, 29 Aug 2024 23:32:16 +0000 (23:32 +0000)] 
Sync the autoconf/Makefile.msc with the main ./Makefile.msc

FossilOrigin-Name: 9de47c3611ca05e03a661807a06c6c5c0b5c6548ea7a8d73cb63832d2dff9d0e

10 months agoAll makefiles are responsive to OPTIONS=... command-line arguments, and add
drh [Thu, 29 Aug 2024 18:32:56 +0000 (18:32 +0000)] 
All makefiles are responsive to OPTIONS=... command-line arguments, and add
the RHS value of OPTIONS= to builds and to lemon and other build steps that
might respond to -D or -U options.

FossilOrigin-Name: 854b3776ee1fcaa5931e3a0ed104978ca350d218e553586d1c40c2420e1be498

10 months agoFix a case where the BTCF_AtLast flag was being left set incorrectly. This was causin...
dan [Thu, 29 Aug 2024 16:27:57 +0000 (16:27 +0000)] 
Fix a case where the BTCF_AtLast flag was being left set incorrectly. This was causing obscure window function queries to fail.

FossilOrigin-Name: e042eb024738a83eed92cd2dfac3d2a50d2589715a3d81b1a494564dd7d8e7fa

10 months agoDo not allow sqlite3_blob_open() to work on a any table that contains
drh [Wed, 28 Aug 2024 19:13:16 +0000 (19:13 +0000)] 
Do not allow sqlite3_blob_open() to work on a any table that contains
generated columns, even columns of the table which are not generated themselves,
because such columns might be part of the expression of a STORED column.
This restriction could be relaxed some, but that would be a lot of code
for something that nobody ever uses.

FossilOrigin-Name: 6e84947123339f0ea2b7dabc6134a621eed09317f81647f15870ed50a0f7d1bc

10 months agoFix a dropped error code in fts5.
dan [Wed, 28 Aug 2024 15:54:46 +0000 (15:54 +0000)] 
Fix a dropped error code in fts5.

FossilOrigin-Name: df55502e4f412e5b1daccf82f11fa4eb932047d9972dcd16e36be00cf09f78e1

10 months agoUpdate the README.md file to recommend running "devtest" instead of "mdevtest".
drh [Wed, 28 Aug 2024 13:55:46 +0000 (13:55 +0000)] 
Update the README.md file to recommend running "devtest" instead of "mdevtest".

FossilOrigin-Name: eb016f66ea2c7ebacf8c57495843db3414602d062e4a430f2cc603c88b10c3f9

10 months agoMaybe [7420b13238da4e6b] was not such a good idea. Restore "make test" so
drh [Wed, 28 Aug 2024 13:51:51 +0000 (13:51 +0000)] 
Maybe [7420b13238da4e6b] was not such a good idea.  Restore "make test" so
that it works as before - running a single-threaded test over the source tree
with options specified by ./configure and similar.  Instead, change the
"make devtest" target so that runs the automated multi-threaded tests on
a standard configuration.

FossilOrigin-Name: dc9fee980d4f4b5a569628702e52cef9e5d8e6c69c2b84546dce47e3e514775e

10 months agoMinor wording change on testrunner output.
drh [Wed, 28 Aug 2024 13:34:20 +0000 (13:34 +0000)] 
Minor wording change on testrunner output.

FossilOrigin-Name: 115e68597957a9ee80de7f554ee3768c992051687c8f07eaf3a9fcaab7efd44e

10 months agoUpdate the "make test" target so that it is really just "mdevtest" with
drh [Wed, 28 Aug 2024 12:10:51 +0000 (12:10 +0000)] 
Update the "make test" target so that it is really just "mdevtest" with
"srctree-check" and "sourcetest".

FossilOrigin-Name: 7420b13238da4e6bfb1589eaf3cfd842fe3c4b0f3b6a3b49c24cd70589bf4809

10 months agoFurther improvements to the status display in order to maximum the amount of
drh [Wed, 28 Aug 2024 11:03:58 +0000 (11:03 +0000)] 
Further improvements to the status display in order to maximum the amount of
information shown on the limited screen realestate available when running
via "watch" or in continuous monitoring mode.  All details are still shown
when doing a stand-alone "status".

FossilOrigin-Name: 557a2c65f5ae1d8cb1858c17da0fe64fbfba83d787cfb7f2f21582960a8b9eac

10 months agoOnly limit the number of failures reported by testrunner status if using
drh [Wed, 28 Aug 2024 10:36:18 +0000 (10:36 +0000)] 
Only limit the number of failures reported by testrunner status if using
VT100 cursor movement.  For a straight-up "status" command, show everything.

FossilOrigin-Name: 791237e0f4b67f0197ae11e966554edeade0c443289d2ade00470d23bf5e8ec8

10 months agoIn the testrunner status display, limit the number of reported failed jobs
drh [Wed, 28 Aug 2024 10:25:44 +0000 (10:25 +0000)] 
In the testrunner status display, limit the number of reported failed jobs
to avoid overflowing the terminal when there are many failures.

FossilOrigin-Name: ffeaa4d5d73871cbdf1ef70b9845d921ebdb96e964d232661a5048cab7d744ed

10 months agoDisable shell test cases that require virtual tables when testfixture is
drh [Wed, 28 Aug 2024 09:47:29 +0000 (09:47 +0000)] 
Disable shell test cases that require virtual tables when testfixture is
built using SQLITE_OMIT_VIRTUALTABLE.

FossilOrigin-Name: 8c73d54fd1e250fcd7f30741cfbd169af9aaecc2096c0c8a9486abaa064d69af

10 months agoReenable SQLITE_OMIT_VIRTUALTABLE on the Device-One alignment for testrunner.
drh [Wed, 28 Aug 2024 09:31:17 +0000 (09:31 +0000)] 
Reenable SQLITE_OMIT_VIRTUALTABLE on the Device-One alignment for testrunner.

FossilOrigin-Name: 8f2cb357634ec0b5aef14f3d967e76db236f8899f3201efc80c264f548cc1b0b

10 months agoChanges to the way "release" tests were constructed in [d03d35eebaf82709]
drh [Tue, 27 Aug 2024 22:28:03 +0000 (22:28 +0000)] 
Changes to the way "release" tests were constructed in [d03d35eebaf82709]
were incorrect.  Fixed here.  Also enhance --explain to chose permutation
configurations and so that PATTERNS on the the command line can match
against permutation configurations.

FossilOrigin-Name: 1f962ffc9e956a9d6311ed9c02fea13c0fe056283ee2c650a2312a258808b3b3

10 months agoImprovements to --status overwrite in testrunner.
drh [Tue, 27 Aug 2024 21:44:45 +0000 (21:44 +0000)] 
Improvements to --status overwrite in testrunner.

FossilOrigin-Name: 26372762ab1451eb95d29367f5b2534bde616a37e5e757e72ba2cfe42571d180

10 months agoAvoid reading the structure record from within the fts5 xConnect method.
dan [Tue, 27 Aug 2024 20:37:30 +0000 (20:37 +0000)] 
Avoid reading the structure record from within the fts5 xConnect method.

FossilOrigin-Name: 6a6ce343b249e269229867b2c2f107a49ac8a8f24ad66801718ef01159655319

10 months agoFurther minor improvements and tweaks to the testrunner --status display.
drh [Tue, 27 Aug 2024 19:49:51 +0000 (19:49 +0000)] 
Further minor improvements and tweaks to the testrunner --status display.

FossilOrigin-Name: 7d1ccc6dfc9abe053baaf39f68e9fb14001f5032a52b85fe1e4b752e48317536

10 months agoFix typo in the previous check-in. Ensure that --status header lines do not testrunner-fix
drh [Tue, 27 Aug 2024 19:48:19 +0000 (19:48 +0000)] 
Fix typo in the previous check-in.  Ensure that --status header lines do not
overflow and wrap.

FossilOrigin-Name: 2eaea67495fd9961b7145d829789889bf1d8fa7a834d40d1be43e7c74c233bc2

10 months agoIn testrunner, when doing the --status updates to the screen, be sure to
drh [Tue, 27 Aug 2024 19:43:21 +0000 (19:43 +0000)] 
In testrunner, when doing the --status updates to the screen, be sure to
overwrite dead text at the end of each line with spaces.

FossilOrigin-Name: 7c195f132cb48ee44124eb4af3532937493429f7c45f6ac611f7a9b128799ad7

10 months agoFurther improvement to the status display in testrunner.tcl. Show the
drh [Tue, 27 Aug 2024 19:28:21 +0000 (19:28 +0000)] 
Further improvement to the status display in testrunner.tcl.  Show the
number of errors and the number of test cases on the status summary.

FossilOrigin-Name: dbc1ac8692feccde271eaca78f2833c8bb7bf620088c8f975692d6ae2c8ba53a

10 months agoModify the implementation of "wrapper" tokenizers to make them more robust in the...
dan [Tue, 27 Aug 2024 19:27:40 +0000 (19:27 +0000)] 
Modify the implementation of "wrapper" tokenizers to make them more robust in the case where the database connection is closed before the tokenizers are deleted.

FossilOrigin-Name: 7c0001d6eb43f89144eb84d9e30f575a3feed401d685a0d1f260692e419b2df2

10 months agoImprovements to testrunner.tcl: Show elapse time in MM:SS or HH:MM:SS.
drh [Tue, 27 Aug 2024 19:17:29 +0000 (19:17 +0000)] 
Improvements to testrunner.tcl:  Show elapse time in MM:SS or HH:MM:SS.
Keep track of the total number of tests and the total number of errors
and report those values on a summary line at the end.

FossilOrigin-Name: 40b232924c973f8d94605946fff75acbe120d90634a2eaf38bd31649e9f1390b

10 months agoAdd test code to drop an fts5 table with corrupt records in its shadow tables.
dan [Tue, 27 Aug 2024 18:25:04 +0000 (18:25 +0000)] 
Add test code to drop an fts5 table with corrupt records in its shadow tables.

FossilOrigin-Name: ca21c942c30a3dbff0e7d118e105b847d80b5388c74d19c2eeea71581f8f40b8

10 months agoUpdates to testrunner: (1) Omit all testing of User-Auth.
drh [Tue, 27 Aug 2024 17:38:26 +0000 (17:38 +0000)] 
Updates to testrunner:  (1) Omit all testing of User-Auth.
(2) Automatically add the "*" wildcard before and after all pattern
arguments.  (3) Build the sqlite3 CLI for release tests.

FossilOrigin-Name: d03d35eebaf82709414c87cfa6abc9d2baf8d7e64c2627bad0fd5bbda3e78d60

10 months agoMerge the SQLITE_USE_ONLY_WIN32 flag for consio into trunk.
drh [Tue, 27 Aug 2024 14:35:54 +0000 (14:35 +0000)] 
Merge the SQLITE_USE_ONLY_WIN32 flag for consio into trunk.

FossilOrigin-Name: e9b03b082dcf141695140a6c2c50bf0dc577c3d64ab76f81dd22f0084eca26d6

10 months agoOnly avoid all C-runtime I/O if the SQLITE_USE_ONLY_WIN32 flag is defined.
drh [Tue, 27 Aug 2024 14:25:52 +0000 (14:25 +0000)] 
Only avoid all C-runtime I/O if the SQLITE_USE_ONLY_WIN32 flag is defined.

FossilOrigin-Name: 164b1e1962aa1e16bdf52e9e86d4cf9c9e09220c0821932ac8e390e82074185f

10 months agoMerge all the latests trunk enhancements into the win-dupe-crt-fio branch.
drh [Tue, 27 Aug 2024 13:57:43 +0000 (13:57 +0000)] 
Merge all the latests trunk enhancements into the win-dupe-crt-fio branch.

FossilOrigin-Name: 2d52db98f47fbcda0622c034b21c2fb19bf4345b88c5c565ae9e6f7128642e43

10 months agoChanges to documentation comments in fts5.h.
dan [Mon, 26 Aug 2024 19:08:54 +0000 (19:08 +0000)] 
Changes to documentation comments in fts5.h.

FossilOrigin-Name: 886545a8d0e9cbf4911ecf747da0ea8aad702d79cb065dad01a04aa4f51da12b

10 months agoRandomize the name of the attached database used to do VACUUM.
drh [Mon, 26 Aug 2024 17:35:32 +0000 (17:35 +0000)] 
Randomize the name of the attached database used to do VACUUM.

FossilOrigin-Name: 0f4e65d73a2b95932f36768c0d9925a2d265d9b395b886d8e492d1d519b2093c

10 months agoshell.c.in: use eputz/oputz() instead of eputf/oputf() where appropriate to avoid...
stephan [Sun, 25 Aug 2024 11:59:29 +0000 (11:59 +0000)] 
shell.c.in: use eputz/oputz() instead of eputf/oputf() where appropriate to avoid compilation errors in -std=c99 mode (namely wasm builds).

FossilOrigin-Name: 9ef8317faebc29d016bdf2e8c678fb21ca2cfa95272f1f18b461fcaf0e220ac5

10 months agoFix harmless compiler warnings in fts5V2toV1Tokenize().
drh [Sat, 24 Aug 2024 20:05:59 +0000 (20:05 +0000)] 
Fix harmless compiler warnings in fts5V2toV1Tokenize().

FossilOrigin-Name: df65d00f104f31741056686f2ba41ecb192c552012bffb17c2a8b5d4db058328

10 months agoFix compiler warnings in the CLI detected by MSVC.
drh [Sat, 24 Aug 2024 20:01:05 +0000 (20:01 +0000)] 
Fix compiler warnings in the CLI detected by MSVC.

FossilOrigin-Name: 23ae505cbfde6dfd1dbb2216cf76c1e316b49f2ca84491a1aae28ad33f7777a9

10 months agoImproved help message for the --enable-test-status configuration option.
drh [Sat, 24 Aug 2024 19:06:52 +0000 (19:06 +0000)] 
Improved help message for the --enable-test-status configuration option.
Fix the build for when that option is omitted.

FossilOrigin-Name: b404a5fe3f0532f6d56b5e65c44a59379c17d175c21ac69a1f2ba8aadf453313

10 months agoNew ./configure option --enable-test-status causes testrunner.tcl to be
drh [Sat, 24 Aug 2024 19:02:33 +0000 (19:02 +0000)] 
New ./configure option --enable-test-status causes testrunner.tcl to be
run with the --status option for targets like mdevtest and releasetest.

FossilOrigin-Name: 9ca8513c26e54c97f2d3c6105c42144100044727f6fb4c28048f7cd7270dd35e

10 months agoRemove a term from an assert() that is no longer relevant.
drh [Sat, 24 Aug 2024 18:42:39 +0000 (18:42 +0000)] 
Remove a term from an assert() that is no longer relevant.

FossilOrigin-Name: 8b4766252b80075354a6b1406c5430fe999a6490aa3e079893fcc682d88734f7

10 months agoAvoid a stack overflow that could be caused by a recursively defined WINDOW() with...
dan [Sat, 24 Aug 2024 15:54:15 +0000 (15:54 +0000)] 
Avoid a stack overflow that could be caused by a recursively defined WINDOW() with a strategically embedded error.

FossilOrigin-Name: bada54bd6bf54190e40aa721b77081015957d204c7b6a9fdbe8c67bcf20798f8

10 months agoEnsure that the WhereLoop.u.btree.pOrderBy field added by the
drh [Sat, 24 Aug 2024 11:48:19 +0000 (11:48 +0000)] 
Ensure that the WhereLoop.u.btree.pOrderBy field added by the
order-by-subquery optimization [7a0cdc7edb704a88] is correctly
initialized.  dbsqlfuzz 437be171a98687082a31ea6efc2fd5c5d64481c8.

FossilOrigin-Name: b75f8b2252aefe7bb96fa237205a1a9dc88c46d9ec09bca7407e6c636b203e7e

10 months agoEliminate use of strcpy() in shell.c.in to squelch an unwarranted link-time warning...
stephan [Fri, 23 Aug 2024 21:20:50 +0000 (21:20 +0000)] 
Eliminate use of strcpy() in shell.c.in to squelch an unwarranted link-time warning on OpenBSD.

FossilOrigin-Name: 32e9bf7f972144eacbb2580151220bc4fc1cbcc8bcf586ffd8e10762abf75c7e

10 months agoFix a problem in the ext/fts5/extract_api_docs.tcl script.
dan [Fri, 23 Aug 2024 17:40:29 +0000 (17:40 +0000)] 
Fix a problem in the ext/fts5/extract_api_docs.tcl script.

FossilOrigin-Name: 9a9d0f6301faefe324261f03543023ffb6a90823349c6946abb0df2f69b31f96

10 months agoAdd fts5 auxiliary function fts5_get_locale(). For querying the locale of a stored...
dan [Fri, 23 Aug 2024 15:18:02 +0000 (15:18 +0000)] 
Add fts5 auxiliary function fts5_get_locale(). For querying the locale of a stored value.

FossilOrigin-Name: 396f720f36a937145ac727c2750acfd26e4eda350b46d648d82a7e9985545a9f

10 months agoEnhance the generate_series() table-valued function such that it is able to
drh [Thu, 22 Aug 2024 18:12:10 +0000 (18:12 +0000)] 
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.

FossilOrigin-Name: d50b784807333c5461a2d027778c746c799285b95bb1952f142b317ea2846460

10 months agoAdd the SQLITE_INDEX_SCAN_HEX bit to the sqlite3_index_info.idxFlags bitmask.
drh [Thu, 22 Aug 2024 16:22:08 +0000 (16:22 +0000)] 
Add the SQLITE_INDEX_SCAN_HEX bit to the sqlite3_index_info.idxFlags bitmask.
When set, this bit causes the EXPLAIN QUERY PLAN output to show the idxNum
value in hex rather than in decimal.  This is purely a debugging aid.

FossilOrigin-Name: 6c00e88ebdb41d6317bb8758825521614dedc2e6e6289ff415c5f0406eed815b

10 months agoAdd SQLITE_TESTCTRL_GETOPT. Use it to implement improvements to the
drh [Wed, 21 Aug 2024 20:25:31 +0000 (20:25 +0000)] 
Add SQLITE_TESTCTRL_GETOPT.  Use it to implement improvements to the
".testctrl opt" dot-command in the CLI, and similar enhancements to TH3.

FossilOrigin-Name: 6500baa9914b08ce19c361a69f19a80e5d800fcb82579d1c1e03601c7a664338

10 months agoAdd the new SQLITE_TESTCTRL_OPTGET that retrieves the current optimization optimization-onoff
drh [Wed, 21 Aug 2024 18:57:55 +0000 (18:57 +0000)] 
Add the new SQLITE_TESTCTRL_OPTGET that retrieves the current optimization
setting.  Use this in the CLI to provide symbolic fine-grain control
over optimization settings using the ".testctrl opt" dot-command.

FossilOrigin-Name: 0ea4e1e8fc689cb1af3a8d21dd6af9d483115412b414e85e8a42480f50d65af2

10 months agoImproved comments on byte-code subroutine calls to materialize subqueries.
drh [Wed, 21 Aug 2024 17:38:50 +0000 (17:38 +0000)] 
Improved comments on byte-code subroutine calls to materialize subqueries.
Should not affect production builds.

FossilOrigin-Name: 6b024c85ef856e26cddac8ad862e16909b5149c3e3efb4e73ba54c97291f1cc4

10 months agoREADME.md: a markup link fix and use the canonical URL for Fossil.
stephan [Wed, 21 Aug 2024 13:57:30 +0000 (13:57 +0000)] 
README.md: a markup link fix and use the canonical URL for Fossil.

FossilOrigin-Name: c49bfee6b878bd96adfc852fdc76e98bf81e2fb82be8325672fbc7af04e7dffa

10 months agoUpdates and enhancements to the README.md file. No code changes.
drh [Wed, 21 Aug 2024 13:44:40 +0000 (13:44 +0000)] 
Updates and enhancements to the README.md file.  No code changes.

FossilOrigin-Name: 3161b8028916bff9a13a04bfb1996bce7e1274a3c403fc58f4d798afd30c528f

10 months agoAdd code comments for a "table-of-contents" and various milestone marks in
drh [Wed, 21 Aug 2024 12:01:46 +0000 (12:01 +0000)] 
Add code comments for a "table-of-contents" and various milestone marks in
the 1300+ line long sqlite3Select() function, to help improve readiability
and maintainability.  Comment changes only - no functional changes.

FossilOrigin-Name: 00cfbb9fa5136e6a7847da4e4ab30d320ca79c22acda9db2030e558d59b8c744

10 months agoFix a minor typo in a comment.
drh [Wed, 21 Aug 2024 10:37:59 +0000 (10:37 +0000)] 
Fix a minor typo in a comment.

FossilOrigin-Name: 92c80af1129051c9eded8df170730ad6366b4f7715dead34c4364c8149d0dce9

10 months agoImprovements to treetrace output for subqueries. Debug code only.
drh [Wed, 21 Aug 2024 10:32:00 +0000 (10:32 +0000)] 
Improvements to treetrace output for subqueries.  Debug code only.

FossilOrigin-Name: 0a835d18d9063b17a1d506fd989ebcf7f0d76593978a3bd5981be59618335f21

10 months agoDe-duplicate some error-output code in shell.c.in as part of tracking down the cause...
stephan [Wed, 21 Aug 2024 09:56:45 +0000 (09:56 +0000)] 
De-duplicate some error-output code in shell.c.in as part of tracking down the cause of [forum:5647ca2af1|forum post 5647ca2af1].

FossilOrigin-Name: fd5904495e0c775174f9380bc6877fb9def3d30dec1c9315979ad4503a18d70b

10 months agoRemove incorrect assert() statements in the SrcItem invariant validator.
drh [Wed, 21 Aug 2024 07:38:14 +0000 (07:38 +0000)] 
Remove incorrect assert() statements in the SrcItem invariant validator.
dbsqlfuzz 7f908865436ce531b0ace55c97a1c71d05c4e76c.

FossilOrigin-Name: 81a1ede38823b8d50e221ecb6ce52a05d82a856099002a71d9f1ac561a587f05

10 months agoRefactor the SrcItem object to move fields associated with subqueries out
drh [Tue, 20 Aug 2024 23:11:28 +0000 (23:11 +0000)] 
Refactor the SrcItem object to move fields associated with subqueries out
into a separate object named Subquery.  This reduces the size of the SrcItem
object by about 1/3rd and provides improved performance.

FossilOrigin-Name: 484bcd75bc95491d8540c791c1c4d40d996cb465839564662e14f98739699bf1

10 months agoFix a name resolution issue with CTEs. srcitem-opt
drh [Tue, 20 Aug 2024 22:44:40 +0000 (22:44 +0000)] 
Fix a name resolution issue with CTEs.

FossilOrigin-Name: 4fa8235dd59cd683d6c6c97bfe181a9637be7c054d435323c903b9dbd74aff02

10 months agoFix minor comment issues.
drh [Tue, 20 Aug 2024 22:05:01 +0000 (22:05 +0000)] 
Fix minor comment issues.

FossilOrigin-Name: c1bbed19f4348ec31c3cb4723eaa8f1554bb58ef4de7feb3a0f39612785f13d5

10 months agoRemove unreachable code.
drh [Tue, 20 Aug 2024 20:01:21 +0000 (20:01 +0000)] 
Remove unreachable code.

FossilOrigin-Name: 17699329aa8e234c6793a38db5ca05def9395b287bcc8bc05493b824327edb59

10 months agoTighter checking of access constraints on union members in SrcItem.
drh [Tue, 20 Aug 2024 19:09:59 +0000 (19:09 +0000)] 
Tighter checking of access constraints on union members in SrcItem.
Improved invariant checking.

FossilOrigin-Name: fd72d3400a8fe5747f494eee81654698acee350bb95b9db269e87d857af03492

10 months agoFix some stray SrcItem field name fixes.
drh [Tue, 20 Aug 2024 17:41:44 +0000 (17:41 +0000)] 
Fix some stray SrcItem field name fixes.

FossilOrigin-Name: bc5f5ce59e1e4323422bda7d002310923f927a03b4fd42749bf04f6c9853956b

10 months agoFix a memory leak so that now all dev tests (including TH3) are passing.
drh [Tue, 20 Aug 2024 17:24:42 +0000 (17:24 +0000)] 
Fix a memory leak so that now all dev tests (including TH3) are passing.

FossilOrigin-Name: 3995c45fff0e4bd10bcf49cc16eb1050216426723c63ba56d3ae5ba738c34019

10 months agoMemory issues fixes so that mdevtest now passes.
drh [Tue, 20 Aug 2024 16:50:21 +0000 (16:50 +0000)] 
Memory issues fixes so that mdevtest now passes.

FossilOrigin-Name: b249516f6a6650808e035ec219e762bf24dcb7c32a6235984b995d08d07d35d8

10 months agoWhen the database encoding is UTF-16LE and the GLOB optimization is used,
drh [Tue, 20 Aug 2024 14:12:16 +0000 (14:12 +0000)] 
When the database encoding is UTF-16LE and the GLOB optimization is used,
it is ok to use the range search over an index, but it is not ok to
disable the actual GLOB function call.

FossilOrigin-Name: 3399698376761ab8c422f8ea02bfa2759afb606f08bedbd1cf7eee834229a9aa