drh
7cd84ffc60
Fix the hash signature algorithm in vfslog.c. Add a utility program to
...
show the hash signatures for every page of a database file.
FossilOrigin-Name: eaf4de13a63b2294ae575432a022493308a4313a
2013-10-10 13:38:51 +00:00
dan
30e2f0ae08
Add ext/misc/vfslog.c, a VFS shim for unix that keeps a log of method calls made by SQLite.
...
FossilOrigin-Name: 24a827b87666670c56d68a18685f4f712852fa92
2013-10-10 13:04:46 +00:00
drh
3d8b2395b3
Estimate row sizes for tables and indices and use those estimates during
...
query planning. Enhance the index_info pragma to show the estimated row
sizes and to show the estimated row size for the main table as well. Allow
an alternative row size estimate to be specified in the sqlite_stat1 table.
FossilOrigin-Name: d27b88b8c2705f444f794096c719e6f38a792165
2013-10-10 12:38:11 +00:00
drh
26586e77d9
Make sure the correct printf format is used for type tRowcnt regardless
...
of whether 32-bit or 64-bit row counts are specified at compile-time.
FossilOrigin-Name: e97d7d3044aa6c5e21d1faab7d5e709d92faa261
2013-10-09 19:07:22 +00:00
drh
1f1fc0c24d
Move a conditional inside of an #ifdef in order to make all branches
...
reachable regardless of compile-time options used.
FossilOrigin-Name: f7cc30d45b77f58c258b21f5823c2b39a44e2bf5
2013-10-08 23:16:48 +00:00
drh
833d198fb1
Fix test cases for the new information in PRAGMA index_list.
...
FossilOrigin-Name: dd03be1065537679c2daf5e4200902c47714fceb
2013-10-08 22:25:22 +00:00
drh
b50596d64d
Rollback some of the previous changes in the branch such that the estimated
...
row sizes are now only used as a tie-breaker for index scans.
FossilOrigin-Name: 65553ff34b41e54d129ff2fee96be714105503c4
2013-10-08 20:42:41 +00:00
drh
5f3e5e747d
Use #ifdefs to omit unused code in the columnType() routine depending on
...
compile-time options.
FossilOrigin-Name: 3fd5e33217a91402b3499fa0977469b91618a928
2013-10-08 20:01:35 +00:00
drh
186ad8cc32
Further refinement of the idea of multiplying run-time cost estimates by
...
the estimated row size.
FossilOrigin-Name: 18bd6ba96d19de6047baebfa15b1f739577c9ec4
2013-10-08 18:40:37 +00:00
mistachkin
86f72f0721
Fix compilation issue with MSVC.
...
FossilOrigin-Name: 36d64dc36f18c166b2c93c43579fa3bbb5cd545f
2013-10-07 21:49:16 +00:00
drh
3495d20dbe
Multiply all cursor step cost estimates by the estimated size of the row in
...
bytes, in order to get the query planner ot make use of estimated row sizes.
This check-in uses magic numbers in a few places (for example, estimates of
the size of output rows) and needs lots of refinement. Consider this a
proof-of-concept only.
FossilOrigin-Name: cb34cfe57c2a664fbfae8106e95114400ea222d5
2013-10-07 17:32:15 +00:00
drh
6f38a6418c
Merge bug fixes from trunk.
...
FossilOrigin-Name: 1d7b2dc0eae70c0c0e523b715acf758bb4cfa9ac
2013-10-07 10:48:06 +00:00
drh
8ab88326cb
Restore the hexrekey pragma which was accidently deleted during the
...
pragma refactoring. Make sure the hexkey and hexrekey pragmas do not
overflow buffers with a over-length key.
FossilOrigin-Name: 0aca31e1514b3df254c049b4251bcb199831681a
2013-10-07 00:36:01 +00:00
drh
793eb043ce
Remove an incorrect debugging assert() that was accidently added during the
...
STAT4 enhancement.
FossilOrigin-Name: 2bb7f74bbd467b74581699d16b06758f9c9457dc
2013-10-06 22:52:51 +00:00
drh
52f6c916fb
Accept the sz=N parameter on table-only lines of sqlite_stat1.
...
FossilOrigin-Name: e9e932aa400f217e383cda9922fbde8a4356f57a
2013-10-06 22:12:41 +00:00
drh
6b169bd86d
Fix an issue in the test8.c test module that arises because of the change
...
to PRAGMA index_list(). Remove an unused local variable.
FossilOrigin-Name: 029430c503f243a34439698779db7e591cfbe126
2013-10-05 20:18:25 +00:00
drh
e13e9f54b0
Completely remove the iScanRatio field. The PRAGMA index_list(TABLE) command
...
shows the estimated row size in the forth column. It also generates a row
for the table with an index name of NULL. The query planner still does not
take row size estimates into account - that is the next step.
FossilOrigin-Name: 8b4aa0c7a2122bbe60432edadf27e490e31ec987
2013-10-05 19:18:00 +00:00
drh
0af62b015a
Improvements to the LogEst command-line tool used to convert between
...
ordinary numbers and the LogEst representation.
FossilOrigin-Name: 5252aeb61988e511dcf8d527fa81e51a5c9385f9
2013-10-05 18:32:30 +00:00
drh
bf539c4d5c
Begin an experimental refactoring to estimate the average number of bytes
...
in table and index rows and to use that information in query planner.
Begin by renaming WhereCost to LogEst and making that type and its
conversion routines available outside of where.c.
FossilOrigin-Name: 66c4a251d61582b47d5cbe50cbca160a9209bd06
2013-10-05 18:16:02 +00:00
drh
6919b07556
In the index_list pragma, make sure the "r" column is the same on output
...
as it was on input in the sqlite_stat1 table.
FossilOrigin-Name: de78250ad2a6210dd4f03045248f7192d64427f2
2013-10-05 02:56:25 +00:00
drh
03e1754e31
Merge trunk changes.
...
FossilOrigin-Name: c6ac80ed8d5240dd30783d62d9f133e159809dec
2013-10-04 20:39:44 +00:00
drh
d3037a4123
Further refinements of the index scanning speed logic.
...
FossilOrigin-Name: e5d9371da92b4cc2c1df177cf40e0ced4d4c7421
2013-10-04 18:29:25 +00:00
dan
5988572876
If an "INSERT INTO ... SELECT" can use the xfer optimization, pass the OPFLAG_BULKCSR hint to btree cursors used to update indices. This results in a tighter key packing.
...
FossilOrigin-Name: 087af29ee2e1572f8668dd0152a14d7f9796a530
2013-10-04 18:17:18 +00:00
drh
165674d8db
Fix test cases so that they work when the query planner uses index size
...
estimates to determine whether or not to try an covering index scan.
FossilOrigin-Name: 2f394de88f23dacd3c61e586a4214ffc6f927d97
2013-10-04 15:58:59 +00:00
drh
fdaac671b8
Improved estimates of the relative speed of index scans based on declared
...
datatypes of columns in the table. Add "r" column to PRAGMA index_info,
showing the estimated relative scan rate.
FossilOrigin-Name: 07462bb6059f023c22a6c84a4a02afbd84e69255
2013-10-04 15:30:21 +00:00
drh
d9e3cad2f8
Progress toward using the iScanRatio information on indices. Many tests
...
are still failing.
FossilOrigin-Name: 6c352edbba85a15ca356b5e131f4b3b2723d1774
2013-10-04 02:36:19 +00:00
drh
5f33f37580
Make sure the count(*) optimization works correctly even when partial
...
indices are present. Ticket [a5c8ed66cae].
FossilOrigin-Name: 9f2f4c0a50808910ad01c8c4352367f25747be08
2013-10-04 00:00:12 +00:00
dan
5db2605a80
Have FTS take advantage of "docid<?" constraints when they are present. Extend the FTS "incremental doclist" optimization so that it is used for tokens within multi-token phrases.
...
FossilOrigin-Name: baf8ce5916ea9baf0ec557263cb9c7ecf716431f
2013-10-03 20:41:18 +00:00
dan
de07791a9c
Merge latest trunk changes.
...
FossilOrigin-Name: 24aa20da222a9cc181473bc41d0f8791be91fa97
2013-10-03 20:28:22 +00:00
dan
9211f8a6ce
Allow FTS4 multi-token phrases to use a combination of in-memory and incrementally loaded doclists. This allows phrases to (partially) benefit from incremental doclists without disabling the deferred token optimization.
...
FossilOrigin-Name: f6819c5f3363d358e7ef65fe6978f13991bd44af
2013-10-03 19:27:14 +00:00
drh
c28c4e5009
Experimental branch allowing different postulated scan rates for each index.
...
FossilOrigin-Name: d59d97b0a8d70dc31d45db61bbc11ebb5375a224
2013-10-03 19:21:41 +00:00
drh
d100f6912d
The sqlite3FixInit() routine cannot fail. So change the return type from "int"
...
to "void".
FossilOrigin-Name: 500c5932fe3f5fcd0940522f7839d581c555e0eb
2013-10-03 15:39:44 +00:00
drh
f63936e805
Rework the PRAGMA implementation to only call sqlite3ReadSchema() from a single
...
place, based on a flag in the pragma table, rather than separately from each
case which needs the schema.
FossilOrigin-Name: 8338232a111be16d6c2ab57176d0a23a001f02ad
2013-10-03 14:08:07 +00:00
dan
46539d7cfa
Return an error if an attempt is made to create a trigger with an SQL variable embedded within it. If such a variable reference is found within a trigger definition loaded from the sqlite_master table, silently replace it with a NULL.
...
FossilOrigin-Name: f35f6ae3da77dbdf5f7a4a9927475659fc6e0ca6
2013-10-03 12:29:38 +00:00
drh
582d47d27a
Remove unnecessary memset() calls from test code.
...
FossilOrigin-Name: eec3187bc68ddebdbc2113f77c7f5cd32e9be61f
2013-10-03 11:27:56 +00:00
drh
01f75f2d68
In the lemon parser generator, change all hashes to unsigned to avoid
...
potential problems with signed integer overflow.
FossilOrigin-Name: 8d399a03de63c15908d63ed69140ee15c6275b8d
2013-10-02 20:46:30 +00:00
dan
eb26672d0e
Add a test to check that the new multi-token phrase optimization is actually helping.
...
FossilOrigin-Name: bc3a2ed5fb2402805928b0002457eebf06f87c47
2013-10-02 08:04:27 +00:00
drh
e75fb06146
Bring some file format comments in btreeInt.h up to date.
...
FossilOrigin-Name: 012d54d0d2b40888d08915082592ba75d70891c1
2013-10-01 20:29:30 +00:00
dan
1073e26435
Merge trunk changes with this branch.
...
FossilOrigin-Name: 65d9c6fafbc19d3582e07c31fd915a70e7fcfa8e
2013-10-01 20:10:26 +00:00
dan
ff574f4c76
Allow multi-token phrases to load doclists from the database incrementally. This allows queries that feature such phrases to benefit from the "docid<?" optimization.
...
FossilOrigin-Name: ea543f081d93ed1bf66c21ce2108ec94e349f4c5
2013-10-01 20:02:32 +00:00
drh
be007dc61e
Fix comments in the fast_vacuum.c demonstration program.
...
FossilOrigin-Name: e0db7b38e1bc0edb1c3995cb23c46488aa6a0909
2013-10-01 19:36:15 +00:00
drh
ba7df1188a
Add the "fast_vacuum.c" demonstration program to the tool/ subdirectgory.
...
FossilOrigin-Name: 2b60320d57a4638ebf97a2854527649c671d108e
2013-10-01 19:02:56 +00:00
drh
4384e98e6e
Change the ".dump" command in the command-line shell so that it COMMITs
...
if there are database corruption errors but invokes ROLLBACK on any other
kind of error.
FossilOrigin-Name: 473234632ff7617680ab151076153f5c1088e55b
2013-10-01 15:30:05 +00:00
drh
24b7fe9004
Fix a minor typo in a comment in where.c.
...
FossilOrigin-Name: 9c9fa151e9a3bdab0264c08b66cbcc89d61bfca5
2013-09-30 19:33:06 +00:00
drh
3b6cb3ceb9
Add some timing tests to the amatch test script.
...
FossilOrigin-Name: ad71c72be56786d8dcf6917efd10a8d3c2d50419
2013-09-30 19:05:03 +00:00
dan
73632e37c9
Merge trunk changes with this branch.
...
FossilOrigin-Name: e294a9c7c525d1da698259c2fef089579bfd1c0b
2013-09-30 18:16:07 +00:00
dan
1f03e609ff
Fix a performance problem in the FTS4 auxiliary functions triggered by an OR clause in the full-text query.
...
FossilOrigin-Name: fa0f2f0e3e79ae653118b901e1cca7725dfaf249
2013-09-30 18:14:45 +00:00
drh
92054fefcd
Fix memory leaks in the amatch extension. Add a few simple test cases.
...
FossilOrigin-Name: 604134732e309a738e21bcb4240b9ff285d2bfe4
2013-09-30 17:37:15 +00:00
dan
19384380f3
Have fts4 full-text queries consider "docid<?" and similar constraints.
...
FossilOrigin-Name: 6622424a3a149edd35ba2ba0881aa41b4536417b
2013-09-30 11:42:19 +00:00
drh
8b8d28dd5a
Update and modernize an obsolete comment associated with VACUUM. No
...
changes to code.
FossilOrigin-Name: 94c914e3fa632f88a0d0c14537f81aa46759e2be
2013-09-30 11:01:28 +00:00