Commit Graph

4747 Commits

Author SHA1 Message Date
drh
33ca481923 Bring the threads branch up-to-date with the 3.8.5 release.
FossilOrigin-Name: e4b01676d7e7ac14f5120ca3a618cc34dbf5dab2
2014-06-05 13:22:52 +00:00
dan
33b7bcb319 Fix a problem that was causing the FTS4 integrity-check command to fail if the table had one or more "notindexed" columns.
FossilOrigin-Name: 7123bb2605216396f65db5d156431b3613f313b5
2014-06-05 11:15:56 +00:00
drh
d0dc5d4984 Avoid closing a pseudo-table associated with sorting in a co-routine since
that pseudo-table might be used again in an outer loop.

FossilOrigin-Name: 6d81805298ea882f5fee99504d5a95f1a762a90b
2014-06-03 14:42:34 +00:00
dan
5a0b8b124b Add a test to double-check that [1cbe7a0883] did not affect anything.
FossilOrigin-Name: c6b512a724aebcd084aad2a80d020b95773b3012
2014-06-03 11:32:38 +00:00
drh
974db61d9d Fix a typo in a requirements mark comment in a test script. No changes to
code.

FossilOrigin-Name: 75ff459b06e1a5c180d316d227ce2f73c99a1f52
2014-06-02 18:24:55 +00:00
drh
2504c6c632 Fix the query planner so that it once again knows that queries without a
FROM clause will never return more than one row and hence do not require
sorting.

FossilOrigin-Name: 9f18b303cd1bc5779d82669884f802c7889b4947
2014-06-02 11:26:33 +00:00
dan
5f43812af8 Add the "valgrind-nolookaside" permutation to permutations.test.
FossilOrigin-Name: 8e8472d9b689d128eb11d3111e009161cf4580f7
2014-06-02 09:39:24 +00:00
mistachkin
110e0ebe6d Revise locking retry semantics in Win32 VFS to abort early if the file handle is reported as invalid.
FossilOrigin-Name: a4df4a5b34111f755ffd9ee6f089ff05d03ebc7a
2014-05-30 21:01:41 +00:00
mistachkin
ff9fcd5a14 Add extra checking of the database extended error code.
FossilOrigin-Name: f2906c44519d76db5bc36013369ae498b80655a8
2014-05-30 16:54:09 +00:00
mistachkin
6b98d67b2b Add tests for the invalid file handle detection logic in the winLock() function.
FossilOrigin-Name: ed5a9eb4f30a395bc641e79254217c7d7cf0aa5d
2014-05-30 16:42:35 +00:00
drh
ff14013496 Merge changes from the trunk into the threads branch.
FossilOrigin-Name: 416cb091267de91b9cadee9f7453b8627570b7d3
2014-05-29 20:24:20 +00:00
drh
c2ce0bea88 Improvements to error messages for errors in the dot-commands of the
command-line shell.  Add the ".once" command.  The output of ".help"
now goes to the designated output channel.

FossilOrigin-Name: 48dce821a07ac29da6ce05e92cf3f6e52b6eb388
2014-05-29 12:36:14 +00:00
dan
3b21f6d62d Add an extra test to verify that the FTS notindexed option is working.
FossilOrigin-Name: c461c0fe051d33cc8b4fede4eca13cd71f28126a
2014-05-28 10:00:38 +00:00
dan
c2070c7d96 Add a test to whereI.test that uses a multi-column PK.
FossilOrigin-Name: aa183e60929bdbbcea3c436dd8cc674fc44ad09a
2014-05-27 11:42:23 +00:00
drh
79045882c9 Merge recent trunk changes into the threads branch.
FossilOrigin-Name: 8215202759dbd863edf20aa26ff21da20bc35d73
2014-05-26 20:15:21 +00:00
dan
f97dad8849 Enable the OR optimization for WITHOUT ROWID tables. Use a temp table instead of the RowSet object to track the rows that have already been included in the result set.
FossilOrigin-Name: 2c7e277bbebd5c93dec53d381d9737909d40d846
2014-05-26 20:06:45 +00:00
dan
6a8ac852aa Fix a problem in the shell when importing CSV files. If the leftmost field of the first row in the CSV file was both zero bytes in size and unquoted, no data was imported.
FossilOrigin-Name: 856d44a206d82e96265103556dedda39ca3602b1
2014-05-26 18:27:12 +00:00
dan
cde81d5fd0 Fix a problem in FTS4 where columns with names that are prefixes of any notindexed column were also being (incorrectly) marked as not indexed. For example in "CREATE ... t1(abc, bc, abcd, notindexed=abcd)", both abc and abcd were being treated as notindexed.
FossilOrigin-Name: d90c4964fcf46b0b043dbfd58267098582267001
2014-05-26 16:40:02 +00:00
dan
e96f2df3dd Changes to the output of EXPLAIN QUERY PLAN to make it clearer when a query uses the PRIMARY KEY index of a WITHOUT ROWID table.
FossilOrigin-Name: 9268df305b90ac11e44b3107bbab5becf38860b7
2014-05-23 17:17:06 +00:00
drh
e48ae7157a Make sure sufficient VDBE registers are allocated for an INSERT...SELECT
when there is an idlist on the insert table that includes an explicit
rowid.  Ticket [9654505cfda93610585fde5a9bbf2e730c8a8d5]

FossilOrigin-Name: 9a2dd18776cc7003752980be0a0920a8799e5f35
2014-05-23 11:48:57 +00:00
dan
6044f31d13 Add a test for the EQP output of a skip-scan query that uses the PK index of a WITHOUT ROWID table.
FossilOrigin-Name: 10238fad94a198c0639461645227b6c5ebe16eee
2014-05-22 09:58:45 +00:00
drh
781597feca Fix the sqlite3_db_readonly() API so that it reports true if the database
is readonly because the file format write version (byte 18 of the header)
is too large.

FossilOrigin-Name: 8d8af114dac301335ec10671c1e9a5a6d8266a60
2014-05-21 08:21:07 +00:00
drh
db2f91907d Merge recent changes from trunk.
FossilOrigin-Name: 6eefdad946da6a5f4052ac51d327777890fa3f18
2014-05-19 23:17:33 +00:00
dan
83e05b814e Fix a broken test case in fts4growth2.test.
FossilOrigin-Name: 9fde5b960af39b187474e5b2909ff0e56d5e0bf9
2014-05-17 15:10:37 +00:00
dan
4bd855fae5 Fixes to prevent an FTS index from growing indefinitely as the corresponding table is updated. Change the FTS 'automerge' option to allow the user to specify the number of segments that should be merged simultaneously by auto-merges.
FossilOrigin-Name: a75f1800021d30b712053373440041b7b355a36a
2014-05-16 16:16:59 +00:00
dan
e82384817d Add extra test to backcompat.test to ensure that old and new versions of FTS may work together on the same incremental merge operation.
FossilOrigin-Name: 3997d47bb9c8593a2cd30317ea65163b99db1832
2014-05-16 15:48:17 +00:00
drh
d25c69ef39 Merge all recent changes from trunk, and especially the new sqlite3FaultSim()
interface.

FossilOrigin-Name: 43fcbd9116401f30781fdcbe55d1674d6b96311b
2014-05-16 14:27:05 +00:00
drh
c007f61bb0 Repurpose the SQLITE_TESTCTRL_FAULT_INSTALL test-control to register a
callback to be invoked by sqlite3FaultSim().  That test-control has been
unused since 2008-06-20 and was never used in any official release.

FossilOrigin-Name: 0d43a7ad9abe821e33e0bf83a997aa4461b1e3f2
2014-05-16 14:17:01 +00:00
dan
a7b9e7d2d9 Fix a bug causing an incorrect segment size value to be stored if both an old and new FTS version performed work on the same incremental merge operation.
FossilOrigin-Name: a9a2aeab298ba2ac0b8835e61406e2d83bf7e39b
2014-05-16 10:30:44 +00:00
dan
5b34f15a82 Do not search for promotable segments following an FTS 'optimize' operation or creation of a new segment on the oldest existing level.
FossilOrigin-Name: 34f6b4b8e4cb8ea45fd518672dc96335d1ce06ab
2014-05-14 19:49:17 +00:00
dan
a0b7ca90b7 Fix a problem to do with loading the value of the FTS automerge setting from the database.
FossilOrigin-Name: 7268119f74602929b372b88eca7b3c3b4964f7d5
2014-05-14 18:45:27 +00:00
dan
9e83e465eb Fix various problems to do with segment promotion. Add test file fts4growth2.test, containing tests to check that the FTS index does not grow indefinitely as the table is updated.
FossilOrigin-Name: 21491a9bc686e63bec32f1a67103622f1160a2f9
2014-05-14 15:58:47 +00:00
dan
c0caea21de Fix a problem preventing delete markers from ever being removed from the FTS index.
FossilOrigin-Name: 7f47ae5c5ddb1227484ddae7c6960183932a052a
2014-05-13 20:11:37 +00:00
dan
6bb9889ef0 Experimental code to prevent FTS indexes from growing indefinitely as the table is updated.
FossilOrigin-Name: b3b505a4dd0c679437a4272109f1188175088cd1
2014-05-12 20:04:48 +00:00
dan
ae289fccbf Merge the latest trunk changes into the threads branch.
FossilOrigin-Name: 9ac8f1e7115bc50663235adedeb0d3e1234c5740
2014-05-09 15:00:32 +00:00
dan
d2d8ca600e Fix the way parenthesis in MATCH expressions are handled by FTS if the tokenizer considers them to be token characters.
FossilOrigin-Name: e21bf7a2ade6373e94ea403c665f78e1ad22143f
2014-05-07 19:59:36 +00:00
drh
eacc050f30 Make sure the group_concat() function returns an empty string, not a NULL,
if it has at least one input row.  Fix for ticket [55746f9e65f8587].

FossilOrigin-Name: 0deac8737545a020d344be96fff16660a7977ab8
2014-05-07 17:19:31 +00:00
drh
731dc0cb0e Add the SQLITE_IOCAP_IMMUTABLE bit as a possible return value from
the xDeviceCharacteristics method in the VFS.  Add the "nolock" and
"immutable" query parameters to URI filenames.

FossilOrigin-Name: 1a0d7d3d9dd54b783e3a805961287dd01f94770c
2014-05-07 15:46:04 +00:00
drh
6451c2b04e Fix nolock and immutable so that they work even if READONLY is requested.
FossilOrigin-Name: e193aced2942e7405d0f45f90d4954b5663b4ba5
2014-05-07 15:32:03 +00:00
drh
62e603a904 Add test cases and documentation for the nolock and immutable query
parameters.

FossilOrigin-Name: 19d56cbaca222b32e2e354063149cccd89441d73
2014-05-07 15:09:24 +00:00
dan
5a7dbc70ea Add a little extra variety to the tests in sort4.test.
FossilOrigin-Name: 7de6aee6a5cb5c7f89dced89f2ebf38f8be7a4fa
2014-05-06 16:21:30 +00:00
dan
dfea45330e Re-implement the core of the multi-threaded sorter tests in sort4.test using C. Run each test in sort4.test ten times, or repeat all tests for 300 seconds as part of the "multithread" permutation test.
FossilOrigin-Name: 208b2b04d4d282bec4424ea7160a123ba549d118
2014-05-06 15:38:07 +00:00
dan
449cb9a5af Add test file sort4.test, containing brute force tests for the multi-theaded sorter.
FossilOrigin-Name: 9cc364c42cc64ab7b55b5c55e303fb63a456cf00
2014-05-05 20:03:50 +00:00
dan
d94d4ee7bd Add tests so that the "coverage-sorter" test permutation covers all branches in vdbesort.c. Fix a few minor problems in the same file.
FossilOrigin-Name: bde28b702dabd02269e333535cc41481351c5efc
2014-05-05 09:08:54 +00:00
dan
f7f425d600 Add an extra fault-injection test to sortfault.test. Remove an unreachable branch from vdbesort.c.
FossilOrigin-Name: a33a366ba8a0da81ddd895d552a348441ef8529a
2014-05-03 20:43:13 +00:00
dan
e18e90ebaf Fix a race condition in the sorter.
FossilOrigin-Name: 32ccf3ae18531682dfd039fa8df6ad9a907ac455
2014-05-03 19:33:00 +00:00
dan
0d51def29e Fix a problem in the sorter causing it to return spurious SQLITE_NOMEM errors when configured to use memsys3 or memsys5.
FossilOrigin-Name: 3a66c4e1bf311d38668dfcdcd77867feff6db7bd
2014-05-03 14:28:14 +00:00
dan
2ae56f50ce Merge orderby-planning with this branch.
FossilOrigin-Name: d9549de31741239ece060e448b592ce8fc5b8042
2014-05-02 18:05:38 +00:00
dan
a7bf23c6b5 Fix some broken asserts in btree.c and vdbeaux.c that may fail following an OOM error.
FossilOrigin-Name: e15f47064bef431c0afd8bf93eb4e160c23ad562
2014-05-02 17:12:41 +00:00
dan
a153643b07 Fix a broken test case in fuzz.test.
FossilOrigin-Name: faa469355eabb2c407f24638b090725448aac37f
2014-05-02 14:54:56 +00:00