Commit Graph

18973 Commits

Author SHA1 Message Date
drh 9881155d54 Change the LEFT JOIN strength reduction optimization so that assumes that
virtual table constraints can be true even if terms within the constraint
are NULL.  This works around dodgy virtual table implementations.

FossilOrigin-Name: cbb977fe1908431f3aad8e67668588b119e7d491724f2042af436f509a4f6623
2018-04-03 14:04:48 +00:00
drh 18e2b8af1c Version 3.23.0
FossilOrigin-Name: 736b53f57f70b23172c30880186dce7ad9baa3b74e3838cae5847cffb98f5cd2
2018-04-02 11:04:16 +00:00
drh 4de3353d4a Better solution to the LIKE problem from the previous check-in that works
even if the SQLITE_LIKE_DOESNT_MATCH_BLOBS compile-time option is used.

FossilOrigin-Name: b850dd159918af568c55c00ff146ba9c9c04d33ff384fe1eb0ad74164bc401bb
2018-04-02 00:16:36 +00:00
drh 1f0ecc79b0 Fix a logic error discovered by OSSFuzz.
FossilOrigin-Name: fc06ddd458fc1028b33b3927cc3b113b7106caa67136993de2e57926a8a19623
2018-03-31 23:28:55 +00:00
dan 4f9a7e5cb7 Fix an assertion failure triggered by a SELECT with a compound sub-query that
contains an incorrectly placed ORDER BY clause. This problem is just an
assert() failure - non-DEBUG builds are not affected. Problem found by
OSSFuzz.

FossilOrigin-Name: 823779d31eb09cda5effe747d9adb35e600a52d4274226586437f674e7824d91
2018-03-31 16:31:51 +00:00
drh 58bd03320d Fix a bug in the spellfix extension causing it to compute suboptimal answers.
The problem was introduced by check-in [afd6fbc01052ccfc9].

FossilOrigin-Name: 3bf28fd9a70ebefc464dceda124d6ed342dd83f71eeeb0568f79e34e731a073e
2018-03-30 16:34:04 +00:00
drh 9f95e48d94 Fix an off-by-one error in the dist3 algorithm of the spellfix extension.
FossilOrigin-Name: 5c34af7b975598bbe20751dfdd346f43031cb2bcb6b78f1bbdb2b51b398de182
2018-03-30 15:59:54 +00:00
dan d99f49fcc9 Another change to test file zipfile.test to help it run on systems without "unzip".
FossilOrigin-Name: b6252feb125db16dabf6ce07568159f0002f9053df1b7b600e2614cc9da24873
2018-03-29 23:54:00 +00:00
dan a8728e7428 Fix a test script bug causing zipfile.test to fail on systems that do not have
the "unzip" program installed.

FossilOrigin-Name: d99022a5a8e4469a87a9fab8a976271e5785524da73ac1d2fae47d00d90fc07a
2018-03-29 16:39:09 +00:00
drh afb39a4cdc Modify the sqlite3OsFileControl() interface to detect unopened sqlite3_file
objects and return SQLITE_NOTFOUND.

FossilOrigin-Name: 1fc72b707d4f4df049c19b023ae3f70cb45d6a6768bb68efc519cfdcd2d2ecda
2018-03-29 13:47:01 +00:00
dan d88690bd10 Update memdb1.test so that it works with SQLITE_DEFAULT_AUTOVACUUM builds.
FossilOrigin-Name: d67f1c7d18d076b18e327ae4e3bccf6086b8f3fd370a7550d77753fc1f1ce07f
2018-03-29 11:02:19 +00:00
drh 928ba14904 Fix a harmless compiler warning in the kvtest.exe program.
FossilOrigin-Name: d48972cf873f8e2499f7c77f8062fde439e7426b616514c147810763469d7c6a
2018-03-28 22:08:44 +00:00
drh 5013c4b9af Fix a harmless compiler warning.
FossilOrigin-Name: f0d12354bba96056f930e5ed3e88c37ec139211be09e6cd6eb7310e979de56c8
2018-03-28 21:45:03 +00:00
dan 3a95c65e37 Add -DSQLITE_ENABLE_DESERIALIZE to the "Device-Two" configuration in
releasetest.tcl.

FossilOrigin-Name: 765a014d8e91be18ac0f12f0fe94f4126bf8ce101f5c9d7f234376e2368f6db3
2018-03-28 20:29:04 +00:00
drh 424981d349 Remove tab characters. No logical changes to code.
FossilOrigin-Name: eb29b3369e76ec1df25a5484d8ec5fb924e23d5c70aaa4d794b2b17ee18784c8
2018-03-28 15:56:55 +00:00
drh 840fda482b Minor comment changes.
FossilOrigin-Name: d282f064698782cf7b584138549a6b27befa0b945ae96b52a3ef6f8a13448077
2018-03-28 15:06:39 +00:00
drh 43a9385def Fix a typo in the README file for ICU. No code changes.
FossilOrigin-Name: 79c4383b66fee9d43a75eef30ed0364573fc99e6d3be12267a99773ab8f57a9f
2018-03-27 22:58:45 +00:00
drh 6a9b9527fa The push-down optimization was being too aggressive such that it sometimes
generated incorrect results.  Reinstate the restriction (4) (with
qualifications) that was removed by check-ins
[b5d3dd8cb0b1e4] and [dd568c27b1d765].

FossilOrigin-Name: f08c1731b0b1dddcba190b094a35306a159713d3db939330f73075ff1d72c81e
2018-03-27 15:13:43 +00:00
drh f900327ed8 Provide the ability for the VFS to do a blocking wait on locks if compiled
with SQLITE_ENABLE_SETLK_TIMEOUT.

FossilOrigin-Name: e7dff982be753bc93123db6a0e8fefd56f2a14fd1c9a8699af0b6b75bc88fc15
2018-03-27 13:57:31 +00:00
drh 000705bcce Do not inject OOM errors on SQLITE_FCNTL_LOCK_TIMEOUT calls as an OOM is
not possible in that context.

FossilOrigin-Name: 5474e560eeb0269964b70bcd876bb86b4197c4fb164bc13454fb8204f083062c
2018-03-26 21:05:47 +00:00
drh fd72563d0a Avoid a race condition that might cause a busy_timeout to last longer than
it should.

FossilOrigin-Name: b81960561b47a1b49646f2f8870dd0684dc4ca7c0b9e11076fd713de66b75972
2018-03-26 20:43:05 +00:00
dan b948948542 Fix a typo preventing test script avtrans.test from running in auto-vacuum
mode.

FossilOrigin-Name: c7473bdb1055df06dc6a93a39ba7f56116f6866292784c4938d843531500c368
2018-03-26 17:56:39 +00:00
drh f0119b2e1b Add infrastructure to support for using F_SETLKW with a timeout on system
that support that functionality.  Requires SQLITE_ENABLE_SETLK_TIMEOUT.

FossilOrigin-Name: 2e54a7433ece4eb27e71bda6f2d121d5aa46ddd5a481357d8543d1432aaad689
2018-03-26 17:40:53 +00:00
drh 80262896d6 Refactor some internal object element names used by the busy handler, to
simplify analysis.

FossilOrigin-Name: 6c40c5574f4ae9795a142d01a8f84afd1b72678ea5f6bfca14a8646c4e862605
2018-03-26 16:37:53 +00:00
mistachkin 43ff906d3e Fix a couple issues in the 'session' module tests.
FossilOrigin-Name: ccf734f7d2bf8f99f3c55124b05c1835e4371bc269f27700f40afc26e7c1bc55
2018-03-24 23:16:05 +00:00
mistachkin 2c42c34df5 Fix harmless compiler warning seen with MSVC.
FossilOrigin-Name: e9508ab1f86ac70a3ca5622ce44141bc05186b199bf32fb8739aef36b95aa05c
2018-03-24 20:06:52 +00:00
drh 821b610b63 Add testcase() macros and improve comments in the LEFT JOIN strength reduction
optimization.

FossilOrigin-Name: 5613457714dd74d6da8e387132a0d8e64980ba4a921a9f53773540b02c0ccec6
2018-03-24 18:01:51 +00:00
drh e3eff266bc Yet another fault in the sqlite3ExprImpliesNotNull() routine, causing errors
in the LEFT JOIN strength reduction optimization of check-in
[dd568c27b1d76563].

FossilOrigin-Name: e88cf3d4df64097ebc19aae464b88d0faf9b7d4c30d057042b582d78327e7ad3
2018-03-24 15:47:31 +00:00
dan 07f119e470 Fix a test script problem causing shell1.test to fail with
-DSQLITE_OMIT_VIRTUAL_TABLE builds.

FossilOrigin-Name: 2e06906e0959e1256fc2feb9dc2c3a9d1e9c19c4ba59585fe52df9af174ab443
2018-03-24 15:08:48 +00:00
drh 2c492061ce Bug fix in the LEFT JOIN strength reduction optimization of
check-in [dd568c27b1d76563].  The sqlite3ExprImpliesNotNull() routine was
mistakenly assuming that a CASE expression must always be NULL if contained
any reference to a variable that was NULL.

FossilOrigin-Name: cf171abe954a5f25262161dd69f2e8cecdbf9446c3f6b298201507dbc743567e
2018-03-24 13:24:02 +00:00
drh b873f4e404 Prepend linkage macros to the sqlite3rebaser interfaces.
FossilOrigin-Name: c64e8f377fe4fa321ebd04806cc27b19287e6fc3523b9988c0a70cad9fce1c18
2018-03-24 00:19:18 +00:00
dan cbeee957e5 Fix typos in sqlite3session.h preventing documentation webpages from being
generated. Also mark all new sessions functions (those related to rebasing) as
experimental.

FossilOrigin-Name: de974235a8fefab0d08673c1b1da4e425e1d8bbfc8c35dac30943c05337b2950
2018-03-23 17:36:31 +00:00
dan 3f2cebb6b4 Fix minor problems with passing NULL pointers to memcmp() and memcpy() found by -fsanitize=undefined.
FossilOrigin-Name: 0b06ce6d8e7cff5cd5d467a94522dfef5593d7c26663ce03c2c2b663a2641551
2018-03-23 16:31:34 +00:00
drh 4aafe5957d Fix the -readonly option on the CLI so that it actually works.
FossilOrigin-Name: 0477fb3fd68509547f3bfd588247aac59aa4aa885ed8a21269852eda64e257ad
2018-03-23 16:08:30 +00:00
mistachkin cf847d44ac Add some more tests for the IS TRUE / IS FALSE operators.
FossilOrigin-Name: 9fe5bebefe909288e583226b5dc32e0465f6b2d8eda850d01820e3f1f8091ddd
2018-03-23 14:56:05 +00:00
drh 8ad427f456 Fix typo in a comment used for documentation. No changes to code.
FossilOrigin-Name: 49974d3b30faaad0891a43d5e840f5dd2dc50ad6c4e6c408292de04e9e8a8868
2018-03-23 14:50:51 +00:00
mistachkin 9d107262e4 Enhance .schema in shell to enable matching patterns with literal underscores.
FossilOrigin-Name: 98e3f5247a6012f58642a2fcdc9be062f7afe8f2e154d06007f4935a0fd87aac
2018-03-23 14:24:34 +00:00
drh f53f88aba6 Fix an error in the CLI in the previous ([0249d9aecf69948]) check-in.
Only the pattern to sqlite3_strlike() need to be escaped.

FossilOrigin-Name: 71d5f6e6322dc037a0e9089049e5d154100b2918830826e30f8043f01a287c00
2018-03-23 13:18:15 +00:00
drh cedfecf90a Fix the ANALYZE command so that it will process tables whose names begin
with "sqlite" as long as they do not being with "sqlite_".

FossilOrigin-Name: 0249d9aecf69948d9343feef9291273beef5fc98aa9a8f95b1e35cc2ce8e6cbd
2018-03-23 12:59:10 +00:00
mistachkin ce2052bc39 Fix harmless compiler warnings seen with MSVC.
FossilOrigin-Name: 2f2be1b1811e6b83fc8945da06e57b8b54233ff8a6ebd9d71b22c6bab2e74afb
2018-03-23 00:31:53 +00:00
dan a968e74fdc Add APIs to the sessions module for "rebasing" changesets.
FossilOrigin-Name: 509506c76b7c104961826721013889d6c6b2ed9b563dcd029e0cb5cb5c34693a
2018-03-22 20:35:20 +00:00
dan 8cb83bee0f Remove some unused code from sqlite3rebaser_rebase().
FossilOrigin-Name: 07cc955eab0e993a75be82d58e17ca53c8abbcaf851983d235049599c19e582f
2018-03-22 20:11:14 +00:00
dan f231e18c6b Fix another problem with rebasing updates against multiple remote changes.
FossilOrigin-Name: c8e7b5a061a3f2fbd9072530177b80f917b39ab5d7cd6acb0a221ab33e78a5cd
2018-03-22 19:52:22 +00:00
dan 516c35a72a Fix an RBU problem causing errors when updating tables with default collation
sequences that require quoting (e.g. COLLATE "ICU_root-u-kn-on").

FossilOrigin-Name: eb4f452e354065d610ff57a6a9312ad119b6b0cc467f9dff105f0718bc27ef01
2018-03-22 17:13:44 +00:00
dan fc50a71be1 Fix a test script problem causing rbuvacuum.test to fail when run along with
other tests.

FossilOrigin-Name: 901cb3b6a2c8d0cc33bd34ec1dbeea49c779ae1ac3ed6733dd9826c8e0eb80c8
2018-03-22 17:02:37 +00:00
dan 3fa5463c03 Add tests to ensure that patchsets are handled correctly by the session rebase
APIs.

FossilOrigin-Name: 0e45baaec01947f6cbf47d5d5922a4cabe7d27181c04c0a08259c952fd023947
2018-03-22 14:07:36 +00:00
drh c6c5ab80ee Add the left join strength reduction optimization. Enhance the push-down
optimization so that it works with many LEFT JOINs.

FossilOrigin-Name: dd568c27b1d7656388ea5b4132cc0265aedd7348d265d8e8c7412b00b28a31aa
2018-03-22 12:00:43 +00:00
drh 66651c2b4b Add the --valid-sql option to the optfuzz test program.
FossilOrigin-Name: a8dfeec73b069f2dd7371c2792b36f152945d32120843db5361ff7e04de177bc
2018-03-22 11:28:31 +00:00
dan b880a7b1f0 Remove some unused code from the sessions module.
FossilOrigin-Name: a09518ab63a1ef1b7f56b9f9b16269fd83920469d4c4e179b1f68b35df4e0c4b
2018-03-22 11:15:59 +00:00
drh 00f0375df7 Get the optfuzz program working.
FossilOrigin-Name: 21346bbce9fd161e8a2037834a6e8eb443a901109ddb3a52c1b7a29000ffeac8
2018-03-21 20:21:29 +00:00