Commit Graph

10813 Commits

Author SHA1 Message Date
drh
5346e95dda NGQP working with virtualt tables, though many legacy tests fail and there
are yet some memory leaks.

FossilOrigin-Name: bd9327a9684b99978734ccd561eea1ad864ab13b
2013-05-08 14:14:26 +00:00
drh
4f58074a80 Fix the wholenumber virtual table so that it returns higher costs for
unconstrained usage.

FossilOrigin-Name: ceff8955020cd1314bf1ab0af7d075fe2c0863e5
2013-05-08 14:13:51 +00:00
drh
a184fb87b8 More bug fixes to the WhereLoop generator and the solver in NGQP.
Now finds the best plan for TPC-H Q8.  This seems to prove the
concept, but there is still much work to be done.

FossilOrigin-Name: 8e5aad37529ec3042e3468acf15186f566e2df8a
2013-05-08 04:22:59 +00:00
drh
f204dac1e3 Bug fixes in the solver.
FossilOrigin-Name: b36034bbd19bc5677b26a6f60ca96eb2b37db373
2013-05-08 03:22:07 +00:00
drh
a18f3d271e Add the NGQP solver.
FossilOrigin-Name: 5d37587c50d8932b6357bfd03152a851510a4317
2013-05-08 03:05:41 +00:00
drh
43fe25fcef Continued progress on generating good WhereLoop objects for the new query
planner.

FossilOrigin-Name: 15cc8a16482777d8e138c4d0863faf8d54fef33a
2013-05-07 23:06:23 +00:00
drh
f1645f0843 Inserting a few WhereLoop objects without leaking memory. Costs are
not correct.  Inequality and IN constraints are not implemented.

FossilOrigin-Name: e8881a8b2f25f38bc8ff77619f96f38fe530d13b
2013-05-07 19:44:38 +00:00
drh
1c8148fffb In where.c, make findTerm() a wrapper around methods to a new WhereScan object
which is capable of finding all suitable matching terms, not just the first.
This check-in includes some prototype functions for building WhereLoop objects.

FossilOrigin-Name: dd92b8fa929badaf2f79e8a00c83667a9d589096
2013-05-04 20:25:23 +00:00
drh
f1b5f5b855 Begin inserting some experimental code for the next generation query planner.
FossilOrigin-Name: ccaf4c3f7e1ec45e058d594d9b5c26818a37722a
2013-05-02 00:15:01 +00:00
drh
a309552e2c Do not use a transitive constraint to an IN operator where the RHS is a
constant if there exists a direct == operator to another table in an outer
loop.

FossilOrigin-Name: faedaeace9c7ed9a8aaf96700caee09db0c0c061
2013-05-01 17:58:35 +00:00
drh
5c10f3b38e Avoid redundant constraint checking due to transitive constraints.
FossilOrigin-Name: 329478cbed06f93652de50abdb31a6b41af02b9e
2013-05-01 17:22:38 +00:00
drh
9a1eccb621 Update the documentation to explain that when the 3rd parameter to
sqlite3_bind_text() and friends is NULL the result is to bind a NULL
SQL value.  Ticket [19b44e35753ba]

FossilOrigin-Name: bd92de0e8d922b96513c5d431493800dda7e7562
2013-04-30 14:25:32 +00:00
drh
3c449c6b6b Make sure extra parentheses around subqueries in the FROM clause are harmless.
Ticket [28c6e830f239ea5].

FossilOrigin-Name: 1c79569226db3d5a73e65a35877635ea8b478866
2013-04-30 14:06:57 +00:00
dan
3a01b600d3 Improve the error message issued when an FTS query exceeds the maximum allowable tree depth.
FossilOrigin-Name: f480b1fe6012f36c59cd0525efdc6df74143ccd0
2013-04-29 18:07:37 +00:00
dan
181f4f789d Fix an off-by-one in the code for limiting the depth of FTS expression trees.
FossilOrigin-Name: 72ac73189c3577740a77d2ea2fc7118391c0703f
2013-04-29 17:12:06 +00:00
dan
f054396b38 Fix mmap1.test so that it passes on windows as well as unix.
FossilOrigin-Name: 52417eac3ecaec2dbbde170334358f5ddbd32501
2013-04-29 09:17:42 +00:00
mistachkin
4eb9b72151 Update 'fuzzerfault' test for its new module loading command. Fix several test names in 'io.test' and make sure the database gets closed between tests.
FossilOrigin-Name: e81e9ca11db09424dd310bbc91686a5daa618cb1
2013-04-29 07:01:23 +00:00
drh
015db9c859 Remove spellfix virtual table documentation from the source tree.
Reference the separate documentation on the website instead.

FossilOrigin-Name: adcf78909ff9064b6e3c4dd15ccd3245c8cf270b
2013-04-27 18:06:40 +00:00
drh
c5797545de Untested fix for building on VxWorks.
FossilOrigin-Name: f14d55cf358b0392d3b8cd61dc85f43a610a8edf
2013-04-27 12:13:29 +00:00
drh
a13090fee9 Fix a formatting typo in a comment. No changes to code.
FossilOrigin-Name: 7a97226ffe174349e7113340f5354c4e44bd9738
2013-04-26 19:33:34 +00:00
dan
8e4714b303 Avoid unnecessarily reseting the pager cache after committing a transaction that takes advantage of the SQLITE_IOCAP_ATOMIC related optimization.
FossilOrigin-Name: c47144e98c0a0f9e09780c945de10c57b6a495ea
2013-04-26 18:36:58 +00:00
dan
77b428aa33 Avoid using posix_fallocate() in WAL mode, as it is not supported by all file-systems.
FossilOrigin-Name: 1bbb4be1a25947f75b2b0c6f368199016b6f7de3
2013-04-26 17:00:52 +00:00
dan
47a2b4a0b0 Avoid using posix_fallocate() in WAL mode, as it is not supported by all file-systems.
FossilOrigin-Name: 9c7523dabf4aee609287732ce787c9b9a9087e7f
2013-04-26 16:09:29 +00:00
drh
9ea88b2b48 Update documentation with new hyperlinks. No changes to code.
FossilOrigin-Name: 640eb54ad6aac9bc7109cba167389a9bcec3f21e
2013-04-26 15:55:57 +00:00
dan
5e2f28c1aa Rebalance FTS expressions after parsing to limit recursion during evaluation. Avoid recursion when deleting FTS expression trees. Enforce a limit (currently 12) on the depth of an expression tree.
FossilOrigin-Name: 49d23ef61f9ce2ffe13237b51a0e01b0b46ba96b
2013-04-26 14:13:15 +00:00
dan
2ea54000a1 Merge another trunk change.
FossilOrigin-Name: 2648966f17bc1b783ef6d3b2368c613f6e02945e
2013-04-26 14:04:28 +00:00
drh
6f77140f78 Fix harmless compiler warnings in the FTS expression parser.
FossilOrigin-Name: 3c78af8c535e16518f18733325f4cd1df7ec8282
2013-04-26 13:14:19 +00:00
drh
2bba8c249a Reduce the default SQLITE_MAX_MMAP_SIZE slightly so that it fits in a
signed 32-bit integer.

FossilOrigin-Name: 460752b8575320163d2659bb7ff24aff41e2bb66
2013-04-26 12:08:29 +00:00
dan
0d02dd8292 Merge latest trunk changes.
FossilOrigin-Name: 4d08e74d34e82f3be588049c9576a5c1008435e7
2013-04-26 06:58:06 +00:00
dan
aa29c86e49 Rebalance FTS expressions after parsing to limit recursion during evaluation. Avoid recursion when deleting FTS expression trees. Enforce a limit on the depth of an expression tree.
FossilOrigin-Name: f968d43f80cc2f236e7d09ba1e8278343e2b6976
2013-04-25 20:34:02 +00:00
drh
ea41dc44c5 Added the nextchar.c extension. Minor changes to the spellfix.c extension
so that it can be appended to an amalgamation and compiled without duplicating
symbols.

FossilOrigin-Name: 56b9a417f5451631f11c5206d625f11472ee65f9
2013-04-25 19:31:33 +00:00
drh
e67f418d10 Fix the tool/build-shell.sh script to remove references to files that are
now loadable extensions.

FossilOrigin-Name: aabeea98f53edde68f484f1794ae70789dac3889
2013-04-25 17:27:08 +00:00
drh
d9555a7927 Add wiki documentation files for the spellfix1 virtual table.
FossilOrigin-Name: 381564e91bbf619f99a48b0b7a94ac586cb9ee79
2013-04-25 17:07:26 +00:00
drh
c140a6b40d Merge the std-ext branch into trunk. This merge adds several new extensions
to the ext/misc folder, including transitive_closure, ieee754, and amatch,
and it convers some older src/test_*.c file into extensions in the ext/misc
folder.

FossilOrigin-Name: bbe607c7d17c50b667990360e2ccfab8dd22f161
2013-04-25 16:52:19 +00:00
drh
8416fc7fc7 Added the transitive_closure, ieee754, and amatch extensions.
FossilOrigin-Name: 84018099c8715b982cd24ce9221f93c7379e8c08
2013-04-25 16:42:55 +00:00
drh
b7045ab2ed Move the test_spellfix.c module to ext/misc/spellfix.c.
FossilOrigin-Name: de556add10150140981a2e34b3712e96a7c262e3
2013-04-25 14:59:01 +00:00
drh
1fb64af1dc Fix the MSVC makefile so that it works with the ext/misc/*.c extensions.
FossilOrigin-Name: 680822e892f3efdb702eea3b321bc5785239dd56
2013-04-25 14:36:28 +00:00
drh
e50db1c5d2 Convert the fuzzer virtual table into a loadable extension and move it
to the ext/misc/fuzzer.c file.

FossilOrigin-Name: c8c69307f60c1d07ac666ae3797b7e3f286fd491
2013-04-25 14:31:46 +00:00
drh
24b6422dcb Make test_wholenumber.c into a loadable extension and move it to
ext/misc/wholenumber.c.

FossilOrigin-Name: efcc9dd012b5f193324dfc2ee9c2410c16fc1b3b
2013-04-25 11:58:36 +00:00
drh
aa87f9a68b Make sure the affinity and datatype of sub-subqueries are initialized
prior to subqueries as the latter relies on the former.

FossilOrigin-Name: 39b4e6ff9316cc78ea88349091e195b8104d1e9e
2013-04-25 00:57:10 +00:00
drh
ed17167e1d Fix a simple comment typo. No changes to code.
FossilOrigin-Name: f136bd95824dc95b9e6acdc4d55db263ba13fbaa
2013-04-24 13:50:09 +00:00
drh
248f2be91a Make "test_regexp.c" into a loadable extension and move it over to
ext/misc/regexp.c.  Add the "load_static_extension" command for testing
purposes.

FossilOrigin-Name: 860fc393bff27045e0593c3c51bf5577accd0b79
2013-04-23 20:10:13 +00:00
drh
da8caa0b2d Fix harmless compiler warnings.
FossilOrigin-Name: 1a1cf5aa86734c832d845e07780262a178188d56
2013-04-22 23:38:50 +00:00
drh
d99aaf10df Do not allow a virtual table to cancel the ORDER BY clause unless all
outer loops are guaranteed to return no more than one row result.
Candidate fix for ticket [ba82a4a41eac1].

FossilOrigin-Name: 49cfa14fceeef2d55b449eb927c283ce6f650c07
2013-04-22 19:56:12 +00:00
drh
4d648c777b Update MSCV makefile for the fts3tokenize virtual table. Clear some
harmless compiler warnings in the fts3tokenize code.

FossilOrigin-Name: 2b3fed09eb89f1e9d6a5f7487ef526b46eb51490
2013-04-22 17:07:56 +00:00
dan
d7a959c694 Add virtual table module 'fts3tokenize' to fts3. fts3tokenize provides SQL access to FTS tokenizer implementations.
FossilOrigin-Name: c5a4b21a15bd8a184380817ff41657acbccb866d
2013-04-22 15:30:37 +00:00
drh
b9830a1454 Enhanced documentation for the SQLITE_CONFIG_SQLLOG mechanism and the
test_sqllog.c demonstration file.  No changes to code.

FossilOrigin-Name: 206caf21f6f6963aa38a9aa0f6ea11c7230bb726
2013-04-22 13:51:09 +00:00
drh
0c41d22920 Use transitivity to move constraints into the outer loops of a join whenever
possible, thereby reducing the amount of work that needs to occur in
inner loops.

FossilOrigin-Name: 5f4907e1c6230e3dd904bd99e1c48c576c669f63
2013-04-22 02:39:10 +00:00
drh
cca17c303b Add the "warning" command to the TCL test infrastructure. Fix problems
with the loadext.test module.

FossilOrigin-Name: 514adbbd8cf3e296f55e8f803bddaac8ad8b2c96
2013-04-19 12:32:52 +00:00
drh
f8b1c69e93 Enhance the extension loading mechanism so that the same source code
can be used for run-time loadable extensions and statically linked
extensions, and to mask architectural differences in shared libraries.

FossilOrigin-Name: a85b6ecefa14fcfe6ebfceabf910f00c3721be7d
2013-04-19 02:47:05 +00:00