drh
60ce5d3135
Add a simple test case for Lemon. Always include assert.h in the
...
Lemon-generated parser.
FossilOrigin-Name: 9c9c46dcbe92aeabe3d5675bb69681b6dfd53798bc67e6a2ceba67ed3c4fb0af
2018-11-27 14:34:33 +00:00
drh
eea8eb6d04
Do not allow direct access to internal-use SQL functions such as
...
sqlite_rename_column() and sqlite3_rename_table() except when the
new SQLITE_TESTCTRL_INTERNAL_FUNCTIONS flag is set.
FossilOrigin-Name: 6e1330545e7b74fe5f1f20751a3425e2788441485fc07fcb7626e448c72027ce
2018-11-26 18:09:15 +00:00
drh
eafb9a0ae5
Make the winTruncate() method of the windows VFS be a no-op if there are
...
outstanding references to the memory-mapped pages. Otherwise, memory might
be deleted out from under those references when the file is remapped during
the truncate operation.
FossilOrigin-Name: ffce4aac18dacbf2a3112ae2ab56c7db20cb164f179683d90a66ef38f4a98f2b
2018-11-24 17:46:07 +00:00
dan
09236755ee
Fix a problem reading from temp databases in SQLITE_DIRECT_OVERFLOW_READ
...
builds.
FossilOrigin-Name: 81629ba91475938b6ad528e7b1dbef4ad22239782bb2e9c1bb59413aba11da87
2018-11-22 19:10:14 +00:00
drh
8055a3ead4
Improvements to the ossfuzz.c fuzz-testing module so that it works with
...
-DSQLITE_OMIT_PROGRESS_CALLBACK and with -DSQLITE_OMIT_INIT.
FossilOrigin-Name: d343f7d6b05865c282eb73a0e39dc396f2927982af45b3d045de03ef73715693
2018-11-21 14:27:34 +00:00
dan
3c425484a7
Fix problems in pragma.c causing some PRAGMA statements to test the wrong
...
schema-cookie before proceeding, or to try to open cursors on the wrong
database ("PRAGMA foreign_key_check" only).
FossilOrigin-Name: 6982f52f579d20b8a2965373731d41622bda7f09fbf82cc005bb378321829f4c
2018-11-20 18:09:59 +00:00
drh
2d588b8c08
Fix the regexp used to recognize libdl errors on OS-X.
...
FossilOrigin-Name: 1740025307531a52e4f0641e2e74dc14715130858f2e9236be13b66924f00220
2018-11-17 14:59:35 +00:00
dan
8e2d4ad30c
Fix a problem in test script e_fkey.test.
...
FossilOrigin-Name: acfd0a05a8957728c1f0eb936f4121ce26f291f20dd583bd57ce2bb271617d3f
2018-11-17 13:08:07 +00:00
drh
d905113e97
Fix a test case so that it works on windows.
...
FossilOrigin-Name: 2d92d25fae5d9757866a0d0b30427b50d635e9b05e12df9464f095419fd7ef3e
2018-11-16 20:50:53 +00:00
drh
32dcc847b5
Enhance the xBestIndex interface of virtual table so that if the xBestIndex
...
method returns SQLITE_CONSTRAINT then that particular combination of
constraints is considered unusable and does not participate further in
query planning.
FossilOrigin-Name: 684013cef6bfcfd920a4aec645df9f5d41ace8b34e75fca61759c1b4f82cc89e
2018-11-16 13:56:15 +00:00
dan
cbfaa076d7
Fix a problem with virtual table "fsdir" and some join queries.
...
FossilOrigin-Name: 7fffcee0fc3fe8d036f0d93ec17673992c3edcf2bb454dc90d80142435b37946
2018-11-16 08:36:15 +00:00
drh
6f147c54ef
Improvements to the CSV virtual table.
...
FossilOrigin-Name: 0406ecbbe75513e342040b71fdd342462222dbb3820486b5f745d7865805c00b
2018-11-16 01:42:26 +00:00
drh
b1b4a3dbca
New fuzztest cases.
...
FossilOrigin-Name: e8316ba47f566c8d2cb48d9d54308e8869743ef39d35b662a8764b0479aed9e0
2018-11-15 13:51:48 +00:00
drh
1ca9a8b9df
Merge fixes from trunk.
...
FossilOrigin-Name: bf88efcec40036e0805940ff6371643dbc518442457d2bc18c711753607ae36c
2018-11-10 03:47:40 +00:00
dan
b430701823
When a table is renamed using "ALTER TABLE RENAME TO", update any REFERENCES
...
clauses that refer to the table, unless "PRAGMA legacy_alter_table" is true
and "PRAGMA foreign_keys" is set to false (i.e. so that when "PRAGMA
legacy_alter_table" is set behaviour is still compatible with versions 3.24
and earlier).
FossilOrigin-Name: ae9638e9c0ad0c366f93c88a850f6b4cc86881e9f3f9f1e39574d9d83ddd8a6a
2018-11-09 20:04:05 +00:00
drh
0b57d312b7
Fix for ticket [787fa716be3a7f650cac]
...
FossilOrigin-Name: 531eca6104e41e4301fa2cf58bb8fec811da31e151a0f766c93aece5521d235b
2018-11-09 14:17:51 +00:00
drh
b7c2cf0aaf
More test-case adjustments for defensive mode.
...
FossilOrigin-Name: 911e8a17a3810cd7042e91a32aba80dc3d6be88320c208e48f7bcee8b22a0ff2
2018-11-07 14:41:08 +00:00
drh
6b758e1d96
Merge the permutations fix from trunk.
...
FossilOrigin-Name: b753d849fe0524e14ae9367a47e29be76332fafb77bfe13e266aeef1ef6742ce
2018-11-07 13:41:27 +00:00
dan
7d0fa14c03
Partially revert [3e1a2f661], as some test scripts require separate $presql
...
and $dbconfig variables.
FossilOrigin-Name: cbf85284beb60d068b446c52f000d694a810d4de9096ad2951523a4c88e7334c
2018-11-07 11:56:23 +00:00
drh
6ab91a7a7a
Add the SQLITE_DEFAULT_DEFENSIVE compile-time option. Fix up test cases
...
so that they work with DEFENSIVE enabled.
FossilOrigin-Name: 3212733cb6d1a59516d67a86df7c7b1d2456a1b2e5d7080c26b0e87b2609c65d
2018-11-07 02:17:01 +00:00
drh
0f0d3ddf71
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.
FossilOrigin-Name: a1d6c6712c3304fd736077432c8c180692cf7d79be7f3a073510b6dab0eb951f
2018-11-06 19:26:04 +00:00
drh
aef15e74c8
Turn on defensive mode for running test scripts. Does not yet work.
...
FossilOrigin-Name: 1c1d24edbb732f2a2002a741c7a7afdd010b67e1b5e6d90ff36c6428897e7612
2018-11-06 15:57:59 +00:00
drh
2d13f6016b
Add the SQLITE_DBCONFIG_DEFENSIVE flag.
...
FossilOrigin-Name: 11d98414eac467affb0b3cf0c7e5cc3d43184fc2b6e7e898bb5277b51ea9e1fa
2018-11-05 19:37:30 +00:00
drh
9196c81406
Eponymous virtual tables appear to exist in all schemas. This is an alternative
...
and improved fix to the eponymous virtual table in trigger problem that
was previously addressed by checkin [1fa74930ab56171e].
FossilOrigin-Name: b8d35c4a7c99ce3753761e5b81269d52c3c910c603fa70b72549883ba68bc485
2018-11-05 16:38:10 +00:00
drh
383bb4fa62
Disable the IS NOT NULL optimization when the IS NOT NULL operator is part
...
of the ON clause of a LEFT JOIN. Fix for ticket [65eb38f6e46de8c75e188a17ec].
FossilOrigin-Name: af39661e60f562b9eb10343fd83e8fe21be4d7276111e7853c1179a24cab09ce
2018-11-05 07:53:17 +00:00
drh
0f1c2eb5f2
Correct the internal logic for SQLITE_DBCONFIG_DEFENSIVE.
...
FossilOrigin-Name: 76094345821246c887a31a234b339d03a78eddbb9fab33b06c3c20797c038349
2018-11-03 17:31:48 +00:00
dan
29d77dc450
Add extra defenses against strategically corrupt databases to fts3/4.
...
FossilOrigin-Name: d44318f59044162e229a444582692e9788f17b5c404b4eb702f4c2114b22fefe
2018-11-03 16:51:30 +00:00
drh
c6e519f335
Fix a assert() in the query planner that can arise when doing row-value
...
operations on a PRIMARY KEY that contains duplicate columns.
Ticket [1a84668dcfdebaf12415d].
FossilOrigin-Name: dcb8c73594ea6b12bad98dc883a585d3e6b925c2ead267dc40332b3d266db5e8
2018-11-03 13:11:24 +00:00
drh
147ad061f6
Enhance triggers so that they can use table-valued-functions that exist in
...
schemas outside of the schema in which the trigger is defined.
FossilOrigin-Name: 1fa74930ab56171e2e840d4a5b259abafb0ad1e0320fc3030066570a6dd10002
2018-11-02 17:38:39 +00:00
drh
a60c63013e
Add support for the SQLITE_PREPARE_NORMALIZED flag and the
...
sqlite3_normalized_sql() when compiling with SQLITE_ENABLE_NORMALIZE.
Also remove unnecessary whitespace from Makefiles.
FossilOrigin-Name: 790ea39a6585ea9f4dad9e132e1fb0447ac1558f728196580d2c3edee84823f7
2018-10-31 19:01:13 +00:00
drh
f8181eaa20
Tweaks to the test_intarray documentation and tests.
...
FossilOrigin-Name: 7107f0dacf4467430d1ca157cb848dde984e48e529e7d67a88b7594b0f8159c9
2018-10-31 18:24:29 +00:00
drh
c985c2822c
Add new fuzzer cases generated by dbfuzz2.
...
FossilOrigin-Name: 79fdad8b42869100845eed36224602452486d0166c18cec7d343040fdac7379e
2018-10-30 23:45:18 +00:00
drh
ad9bfa5e07
Improvements to the -fsanitize=fuzzer based database file fuzzer.
...
(Cherrypick from the rubust-against-damaged-db branch.)
FossilOrigin-Name: 3cc01a0eaf54e3d5adf206825cfcab15edf73bd5aea10dfc497efd78071a17d0
2018-10-30 15:20:35 +00:00
mistachkin
8bee11a41e
Add the sqlite3_normalized_sql() API.
...
FossilOrigin-Name: 592b66e8058dd03a056a036e2606247c9efdb06d15eebe9bcc455f7f55e30ae6
2018-10-29 17:53:23 +00:00
drh
d811d844cd
Improvements to the dbfuzz2.c test module.
...
FossilOrigin-Name: d60eff493b875366981c5a25000bb65cde9f6e628192914910790acc562c17b9
2018-10-27 21:06:44 +00:00
drh
65da285e6a
Initial code for a fuzzing tool on database file that works with the
...
-fsanitize=fuzzer option of clang.
FossilOrigin-Name: 90d12094d36957fbded71545add8a5dc206798fdacc17d4d161d715569a7f991
2018-10-27 00:47:33 +00:00
dan
f689400dc7
Prevent an == constraint specified using the table-valued-function argument
...
syntax from being used to optimize any scan not related to the virtual table
for which it was specified as an argument.
FossilOrigin-Name: 4d46685f282409f7154be288719cbea4b743d7ea5315a55a91462003497469f7
2018-10-26 15:36:53 +00:00
drh
8e5bfedd22
In the WHERE-constraint propagation optimization, if there are duplicate
...
constraint, make sure only one of them propagates. Proposed fix for
ticket [cf5ed20fc8621b165].
FossilOrigin-Name: 5d5b596f152bb2781011a05f75f9e200774d4f69d648ef68de577b4ace973e07
2018-10-25 14:15:37 +00:00
dan
0f5f54062c
Fix a problem with using window functions in compound (UNION, INTERSECT etc.)
...
queries.
FossilOrigin-Name: 059ff53a46c7f1e4bf3e7dc558312beef67826c2753e2ab7e4e7df498b37b617
2018-10-23 13:48:19 +00:00
drh
bafad06139
Test case modifications to support SEE.
...
FossilOrigin-Name: 02b6f8f2778c371130c512e980c3db07c7e76dcf7dd92a878b86e4b6a47ca307
2018-10-12 15:01:56 +00:00
drh
b6c4d59e89
In the unix VFS, fix the heap shm allocator (used for unix-excl)
...
so that it works even on systems where the page size is larger than 32KB.
FossilOrigin-Name: 7fbb083c5cf0948af3624b7538ffa086f77de27a3e84a7039ae7d6574f1a3a54
2018-10-11 02:39:11 +00:00
dan
07052d5535
Add test cases and assert() statements to ensure that the authorizer is being
...
called as expected from within ALTER TABLE.
FossilOrigin-Name: ff10d2c7de430c88167b1e6e4f5307eee5d69e22c8d24b2ef4fcb3aea25a92e1
2018-10-06 13:46:22 +00:00
drh
bfbf7d9daa
Test case for PRAGMA table_xinfo.
...
FossilOrigin-Name: 7694b9bc3003db6ba0b41c5029c8f7b84c07724e7a518e835e98b3c46e4ea227
2018-10-01 21:36:38 +00:00
dan
5351e884aa
Fix a problem with ALTER TABLE commands when the schema features an INSTEAD of
...
trigger that uses NEW.* or OLD.*.
FossilOrigin-Name: c52f457e56eb9d573eb67093731eb231aaf6fd6dbdc397e6f948b82736fbe3ab
2018-10-01 07:04:12 +00:00
drh
ca9a5faf70
Fix test cases so that they work with ICU.
...
FossilOrigin-Name: d04b2013b5436430ebbf7053d637fd89c1b15affcb42787dcf1cf5ffc3ae54e2
2018-09-28 23:53:24 +00:00
dan
6afa35c985
Disallow the use of window functions in the recursive part of a recursive CTE.
...
FossilOrigin-Name: 7fc2994434c7d9ed29c96a69c07e8eb4e97be776473c170c63f9a1bbaa09fa68
2018-09-27 12:14:15 +00:00
drh
98aa2abc45
Begin revamping the ".help" command in the command-line shell so that it
...
can accept an argument and will do a search for commands that match that
argument.
FossilOrigin-Name: 209afb8d06466536863b89a8acb9a1a18477a06331d8cce95fc6380e1666b6f5
2018-09-26 16:53:51 +00:00
dan
6705584a5b
Fix a problem in releasetest.tcl causing configuration "Fast-One" to fail.
...
FossilOrigin-Name: 42e04fefbc241dd33f12abd66344a87720ae4cda6d82f2882217b3cb71be8733
2018-09-25 13:51:31 +00:00
dan
2fae150402
Fix a problem with views that use window functions as part of complex expressions.
...
FossilOrigin-Name: 507d892c3a40a0bacbd47ed3c4fe2d8925a82716ae08da8401750a42782ba454
2018-09-24 14:51:59 +00:00
drh
f8937f9034
Fix a faulty assert() in the validation logic for the LEFT JOIN strength
...
reduction optimization. Problem found by OSSFuzz.
FossilOrigin-Name: 2fd62fccd13e326dbd7dd730112542c6faa56e466bf4f7b8e22ced543031280c
2018-09-23 02:01:42 +00:00