dan
7c492a250b
Fix an "ifcapable" expression in values.test.
...
FossilOrigin-Name: b8442d2a6012b1f2e15381613267db0982e36bb4c748b15b56e668e0d0a3d0d2
2024-05-24 13:33:39 +00:00
drh
e6d3c57204
Fix the window-function group_concat() so that it returns an empty string
...
if it has one or more empty string inputs. This fixes
a bug introduced by [c6da39115d3e2b0f] on 2019-03-26 (version 3.28.0) and
reported by [forum/forumpost/bf8f43aa522c2299|forum post bf8f43aa522c2299].
FossilOrigin-Name: cec6bb3fc9932ea78ec8e63d9c2d4e56a4d94b8973b9ea46033cc4baa87c0476
2024-05-23 23:26:04 +00:00
drh
294cd87afc
Merge various enhancements that were being held on a branch until after the
...
3.46.0 release. (1) Allow arbitrary expressions in the second argument to
the RAISE() function. (2) Performance optimization to the OP_OpenRead and
OP_OpenWrite bytecode operators. (3) Allow FTS5 tables to be dropped even if
the associated tokenizer is not available. (4) Performance optimizations in
FTS5. (5) Generate better bytecode to improve performance of ONEROW scans.
FossilOrigin-Name: 1e5385ffc30743412ade1536583504eec36790cac5355042aa1e12d8d2271d1f
2024-05-23 15:05:57 +00:00
drh
18ec0d4a34
Increase the version number to 3.47.0 to begin the next development cycle.
...
FossilOrigin-Name: 20e228a22e4c5a8d62fae003ac176de62126d8e121871c5ca14a5480c4d4b6a2
2024-05-23 14:58:31 +00:00
drh
bebe2d8be8
Version 3.46.0
...
FossilOrigin-Name: 96c92aba00c8375bc32fafcdf12429c58bd8aabfcadab6683e35bbb9cdebf19e
2024-05-23 13:25:27 +00:00
dan
3731703dbb
Ensure an sqlite_dbdata cursor is properly reset before being used again, even if it has already encountered database corruption.
...
FossilOrigin-Name: 3210e1ca4d0efedf9710c97abd050ba10d3af98cb1f029c26daa84daf42fbc7e
2024-05-21 17:37:50 +00:00
dan
2526668556
Do not attempt to run mmapcorrupt.test with builds that do not support mmap().
...
FossilOrigin-Name: 54a49f1847f95c377f0f611eb10f635b879bba8c2eb25e65e2f66a56f4f9a505
2024-05-21 14:54:46 +00:00
drh
33087dbf30
Fix harmless compiler warnings.
...
FossilOrigin-Name: aab59f9f7c1c4cfac4d29d7c7a381583295312baf3b9a75e30a617b1541e12e1
2024-05-21 13:34:26 +00:00
drh
b8337932b3
Fix the -> and ->> operators so that when the RHS is a string that looks like
...
a number, it is still treated as a string, because that is what PG does.
[forum:/forumpost/9e52cdfe15c3926e|Forum post 9e52cdfe15c3926e].
FossilOrigin-Name: de8182cf1773ac0d04268d896a613841cf6bf61f9f030342170657d5e06f2acb
2024-05-21 11:11:29 +00:00
drh
00208479fd
Omit a capi3 test from 2007 that depends upon undefined behavior (UAF).
...
FossilOrigin-Name: a60a0b75137c015e97b8dcd0070444fcb608f502ce88b2ee744dd6230dbdc120
2024-05-20 19:59:32 +00:00
dan
f765aec406
Do not run the tests in recovercorrupt4.test with the inmemory_journal permutation.
...
FossilOrigin-Name: c13205d66b8406cccfc937c88ac515fa758fe2ade8b3d30f0c1e79fe974e9600
2024-05-20 19:51:06 +00:00
drh
e212493358
Improvements to the documentation of sqlite3_vtab_distinct(). Do not allow
...
sqlite3_vtab_distinct() to return 2 or 3 if the rowid column of the virtual
table is used, as doing so might lead to an incorrect answer.
FossilOrigin-Name: 08058d66d1bde4fcf8324482ee4c6c030c681383470d5076b6f75b74aac2ae29
2024-05-20 17:52:35 +00:00
drh
df903fe056
Improvements to the sqlite3_vtab_distinct() documentation.
...
FossilOrigin-Name: 6ee041d34f292b94701919f51bbb9e12bcb9e0c4f45e4c0b83f30ff328070637
2024-05-20 16:00:27 +00:00
drh
0462499051
Fix the definition of sqlite3_vtab_distinct() such that return codes 2 and
...
3 mean that all rows must be distinct over "colUsed" which is a superset of
"aOrderBy". Also, disallow return codes 2 and 3 if the rowid of the virtual
table is accessed.
FossilOrigin-Name: 922731ce98c0ce7837784ff7966049e59fa73da2aa04abf3506503b6fc4aa048
2024-05-18 20:00:08 +00:00
stephan
79dac84b31
JS error message and doc typos reported in the forum. No code changes.
...
FossilOrigin-Name: 1a073f9acfb691eebf4a8cc78a72ff47ebbb6aba4acede6755fa3faefae48f2b
2024-05-18 15:21:45 +00:00
drh
b834f629cc
Improvements to a VDBE comment. No changes to anything that affects queries.
...
FossilOrigin-Name: c2188da860a1debd7c5d28b223deeef15035c33c2c5aefae9d9b620b6a2b4677
2024-05-17 22:51:03 +00:00
dan
c83386cbe5
Merge branches "fix-onerow-opt", "faster-openread", "fts5-delay-tokenizer" and "enhanced-raise", each containing minor enhancements prepared for 3.47, into this branch.
...
FossilOrigin-Name: 6dc6472175bccbed15ebf6811c209d1a0b5fad60158fb32040210f2cdae916a6
2024-05-17 14:26:32 +00:00
dan
0445cd1020
Fix a problem in where.c preventing SQLite from identifying some ONEROW scans, leading to (slightly) sub-optimal byte-code.
...
FossilOrigin-Name: b41e71208abcdf988f57c3fd7e6a372bbaf442c32a8e2c051beb8d45c8001e0f
2024-05-17 13:56:38 +00:00
dan
fa0763eb34
Add extra tests for the error messages generated by sqlite3_declare_vtab() when passed something other than a well-formed CREATE TABLE statement.
...
FossilOrigin-Name: 5fa0c2a026f0467af3a76ea80cee8168b7a49553c350f642d1dff02ff9e7aeed
2024-05-16 16:22:51 +00:00
drh
c72953a4bc
The sqlite3_declare_vtab() interface should return SQLITE_ERROR, not
...
SQLITE_MISUSE when a nonsense SQL input is provided, for legacy compatibility.
[forum:/forumpost/4b875d7b2a|Forum post 4b875d7b2a].
FossilOrigin-Name: 1ec2961a0341619ae88832942b52606b3246fc0de07ca6da0300e4bfc656ecf0
2024-05-16 15:57:42 +00:00
drh
c4439fb134
Fix a case where an error in the ORDER BY clause of an aggregate function that is part of a trigger body might cause an assert() to fail in an ALTER TABLE command. dbsqlfuzz 899d9255555a07f1fe11a0bb51a2fe197b3150cd
...
FossilOrigin-Name: 953271f29e7bd6ba9b85f73250b1c22b08eef317f9ac3c7c3d92cbaa57d7efd5
2024-05-16 00:20:43 +00:00
drh
61f2ee6ab8
Back out the assert() fixes from [a9443dbfbe25e588] and
...
[3afaeac56dff58db] (but keep the corresponding test cases) because they
are both made obsolete by the previous fix on this branch.
FossilOrigin-Name: 3120c7c8a3565b8a3ca321129c09db96839c2f9af1777fc7a1668fef81973603
2024-05-15 23:36:24 +00:00
dan
1550771a6a
Fix a case where an error in the ORDER BY clause of an aggregate function that is part of a trigger body might cause an assert() to fail in an ALTER TABLE command.
...
FossilOrigin-Name: b79a8be37b44c1eff7d00f7af7cd9d0e13614ce5961bb88ddb9ec63f6a846c78
2024-05-15 21:38:04 +00:00
dan
9a1a4822e8
If there is no data available for a field in a corrupted record, but the type is available, have the recovery extension substitute 0, 0.0, '' or X'' instead of a NULL value.
...
FossilOrigin-Name: 8eb326c24981647e2df90e4b9d75db52a552bd997bd821f5898c7ff3fb93a57d
2024-05-15 15:06:27 +00:00
dan
a0693f21fc
Optimize queries against fts5vocab(row) tables that do use the "cnt" column.
...
FossilOrigin-Name: 96a591c202cb4218999ece3de063bf466b6fd81bd23383893f3913ecb52dda36
2024-05-14 19:41:19 +00:00
dan
433af7ab93
Avoid calculating the value of the "cnt" column for fts5vocab(row) queries that do not use it.
...
FossilOrigin-Name: c0c91e306c252ce1b398e92ab958e2a3de0fc43db05cfdffc548380654fc9f13
2024-05-14 19:09:54 +00:00
dan
32ca0dbcdf
Have fts5 tables delay initializing the tokenizer until it is first used in all cases where the tokenizer is not "trigram".
...
FossilOrigin-Name: ca4fdcb8ae95d2a61236b949f852d2bf25ea2dbbff7eedafbd8eb84e8fd96687
2024-05-14 17:16:09 +00:00
dan
12b205c637
Allow existing fts5 tables to be dropped even if the associated tokenizer is not available.
...
FossilOrigin-Name: 69ef47eeee8b53684c321393be34f03600694fbc86377f8720ff80307846aff6
2024-05-13 20:06:08 +00:00
drh
4f59d09648
Optimization in the implementation of OP_OpenRead and OP_OpenWrite
...
FossilOrigin-Name: 3a256a1667b15702dc5048fdf2fdba9c1e551106ce8cf391360f156fab35ecc5
2024-05-12 00:26:08 +00:00
dan
f722d91fa8
Add tests to bestindexC.test. No changes to code.
...
FossilOrigin-Name: 58d938c0e03c3c8d8796c537f89e69734ba6263d60ba37e345259cb6fdffbea5
2024-05-11 16:44:56 +00:00
drh
5d783d5c84
Fix aggregate function processing to correctly deal with OOMs inside of
...
sqlite3ParserAddCleanup().
(dbsqlfuzz b2d11ca70e55ee8bde48ae0b53fa3e9355812f95).
Also add improved testing support by causing sqlite3FaultSim(300) to
simulate an OOM inside of sqlite3ParserAddCleanup() and by adding
improved fault-sim support to the CLI.
FossilOrigin-Name: c6fd70b3c23fa00eaac9286d4a67e5c8ac76f926c11c220250c34032647bedc1
2024-05-10 18:24:15 +00:00
dan
e09e451a48
Add a test for the fixes on this branch.
...
FossilOrigin-Name: 716088d673b80446ea5f9cb83f6aad8a9ea2ec769d4894e02ab916930e4cf169
2024-05-10 18:15:03 +00:00
drh
325420616f
The sqlite3FaultSim(300) error from [1e8863909ac369e5] must be treated as
...
an OOM, since it simulates an OOM. Also fix deferred deletion of Expr objects
from [a53bdd311c4154fd] so that it does not corrupt the AST if an OOM occurs.
FossilOrigin-Name: c623d9a51e0ae6b4a8e1186714d14e7aa3df55246e123323481f07f07749dea5
2024-05-10 18:10:34 +00:00
drh
0e4afddadf
Improvements to the ".testctrl fault_install" command in the CLI.
...
FossilOrigin-Name: 48b34ded82d0cec8a7dd67431f057b320b8c459b1b78c0fbf79bc2b355e85d4e
2024-05-10 17:05:24 +00:00
drh
7e60106d15
Add an sqlite3FaultSim(300) call to the sqlite3ParserAddCleanup() routine
...
for more precise simulation of OOM errors in that routine.
FossilOrigin-Name: 1e8863909ac369e5e62e82e53b6e5a7cc6794100cef281ede00b0bb9bbc28594
2024-05-10 16:28:35 +00:00
stephan
8292aa7a18
Squelch two OMIT-flag-related warnings reported in [forum:388243d9882067a9|forum post 388243d9882067a9]. No functional changes.
...
FossilOrigin-Name: 1d6716054d7fc50df237996c3db30e5fb8e32acbf48cb8b9af472360515945c4
2024-05-10 09:26:53 +00:00
stephan
a8c43830f2
Add a maintenance-reminder comment explaining [dc58ed65492857].
...
FossilOrigin-Name: 857f5d7fadce1cfe30b3468826f403f736cfecacb1eb6d3b858b01ea3cfd6ffc
2024-05-09 18:39:54 +00:00
stephan
0e93237b17
Reformulate a for-in loop to a for loop in wasm.xWrap() to work around a downstream framework-level misbehavior, as reported in [forum:b549992634b55104|forum post b549992634b55104].
...
FossilOrigin-Name: dc58ed654928574ef254af289bd21c654c587aac80aea36ab96772c35d4ca754
2024-05-09 18:00:14 +00:00
stephan
f0c9bc596e
Rename a shadowed local var, as reported in [forum:2ba65af3148585cf|forum post 2ba65af31]. No functional changes.
...
FossilOrigin-Name: d030c87c4d410e9ca2b90ec7cb63e752f4490c60e2feac84f233861593142c7d
2024-05-08 17:57:45 +00:00
drh
788ade3487
Allow arbitrary expressions as the second argument to RAISE().
...
FossilOrigin-Name: 003e1c8c27824cb917b3869bdf9000f32ff0b6887a2aff8516712cfe865cf34d
2024-05-08 17:42:13 +00:00
drh
538ad6ce58
Fix a hyperlink typo in session documentation.
...
FossilOrigin-Name: 42d67c6fed3a5f21d7b71515aca471ba61d387e620022735a2e7929fa3a237cf
2024-05-08 11:51:56 +00:00
dan
d1122a4c0f
Fix bug in test script sessionconflict.test.
...
FossilOrigin-Name: e29decb8b1991bb586f41fd74bbaa4d6c4bd63e22617145828b2500d697d7869
2024-05-07 19:45:05 +00:00
dan
a40cae7802
Ensure successive scans of pragma virtual tables return consistent rowids.
...
FossilOrigin-Name: 6838bf3ac130c5862f5fbc718b3e49ece154fa840b6539af2616cffa31e73808
2024-05-07 17:58:07 +00:00
stephan
e871779f7e
Fix a compilation error in test/lemon-test01.y, reported in [forum:f0ad095705|forum post f0ad095705].
...
FossilOrigin-Name: 576b68c8b5132eb8901789b7fafb37e5ad7a00c1c7154090b42ddc5934ac0396
2024-05-07 13:20:24 +00:00
dan
11a088b7eb
When extracting links from sqlar archives, clobber any existing file or link, and do not call utimes() to set the timestamp - it looks through the link and operates on the target.
...
FossilOrigin-Name: 2bf8c3f99ad8b74f707d17272fa12b674bec66082d3e8349ebef3dac42ba0782
2024-05-06 20:21:31 +00:00
drh
07305e3a3a
Omit redundant unary + operators from the AST.
...
FossilOrigin-Name: f81cc149e5e308785502b36e83eaaf3d31c72520793e0596d5496abd70f9cda8
2024-05-06 20:18:30 +00:00
drh
ebf9702b34
Avoid unnecessary recursion in sqlite3ExprDeleteNN(). This complicates the
...
code, but it is needed to prevent nuisance "stack overflow" reports from
OSSFuzz while it is running the latest ASAN.
FossilOrigin-Name: 70abc144ca90a58ea25dc2d90683545246c084d961215c20ec070b0abe640371
2024-05-06 19:04:46 +00:00
dan
f4744ff1ff
Add new sessions API sqlite3changegroup_add_change().
...
FossilOrigin-Name: 5eaab43ce48bb8d710f784ecd6aa9a4b3e708b44b0f7e49daf66a3f8bc2b9873
2024-05-06 17:55:19 +00:00
dan
cbea8d5c3f
Edit comments in sqlite3session.h.
...
FossilOrigin-Name: 49f84878e21f85d44d8429cdc2908f87383e59737e1af3fdbccf0c276d883567
2024-05-06 17:32:26 +00:00
dan
0f78aafec8
Add tests for sqlite3changegroup_add_change().
...
FossilOrigin-Name: 9d67bedc20c3a59e5488f0eaea6a6611940a9cb63f7cf5e687b061cb5d510943
2024-05-06 17:21:23 +00:00