drh
4d79983ca5
Optimizations to the new EQP framework.
...
FossilOrigin-Name: 956fef361a795bd081d8e23ce4075dc8aafcee63ab7275d13b657b529d185b30
2018-05-03 19:47:14 +00:00
drh
e2ca99c907
Begin reengineering the EXPLAIN QUERY PLAN function to provide more
...
intuitive output.
FossilOrigin-Name: 70b48a7972dfbb44af3ccd8ccd830e984bec88d80a78b3566a5de86a16e7fc14
2018-05-02 00:33:43 +00:00
drh
6876dccbfe
The previous fix for ticket [d85fffd6ffe856092ed8da] in check-in
...
[0a514e62ad1ebe5c12da8dae] did not completely address the
probably in that it only worked for cases where the OP_SCopy that loaded
the register was the last instruction in the sequence for the expression, which
is not necessarily the case for expressions like CASE...END. This revision
prevents the registered that will be recomputed from being cached in the first
place.
FossilOrigin-Name: 9fd0faf517993587d2f54212638545fc85fbbc84a031bcfae8c1e5894825d83b
2018-04-26 18:34:26 +00:00
drh
909066bba0
Ensure that new.* values of an UPDATE do not get clobbered after the
...
BEFORE triggers run when unmodified columns of the row being updated are
reloaded. Fix for ticket [d85fffd6ffe856092ed8da]
FossilOrigin-Name: 0a514e62ad1ebe5c12da8daed429ae2f9d9910471d3c5cef3b6870bdadfefca1
2018-04-26 15:50:10 +00:00
drh
9916048b89
Add new testcase() macros and fix a bug that was revealed when trying to
...
cover all the new test cases.
FossilOrigin-Name: 266a99f7c068aadbd08157d1d495a428109ad7a32d872f8026e8db0f89c40f91
2018-04-18 01:34:39 +00:00
dan
614efe2b4b
Experimental change to include changes made to the sqlite_stat1 table in
...
changesets generated by the sessions module. sqlite_stat1 entries in such
changesets are ignored by legacy clients.
FossilOrigin-Name: bd46c4429693545eb16db85692fc591ac529796aa746f5f21df1ce4380619320
2018-01-12 16:44:29 +00:00
drh
6e97f8ec84
Combine the Parse.ckBase and Parse.iSelfTab fields into just Parse.iSelfTab.
...
This fixes a problem with date/time functions in check-constraints. Add
some test cases for date/time functions in index expressions and check
constraints.
FossilOrigin-Name: 22eda0985ecd1f456c073e6ad735a8417f3ff1fb6aaad1640e1cec01e50c51d8
2017-07-20 13:17:08 +00:00
drh
3e34eabcdf
Allow indexes to be created on date/time functions as long as the 'now'
...
date and the 'localtime' and 'utc' modifiers are not used.
FossilOrigin-Name: 0a5e1c04d9d07bb7fd6546a9ddac1bf42b19ea19c2b79570aea6cd4226887a27
2017-07-19 19:48:40 +00:00
drh
0c2433003d
Smaller and faster implementation for vdbeFreeOpArray() and freeP4().
...
FossilOrigin-Name: 0c80593520d30958231be41fc443209eb39e0b3ee0e66308c3ef3a0f4cb8ea66
2017-07-12 20:43:23 +00:00
drh
2c2f392dca
Add interfaces sqlite3_prepare_v3() and sqlite3_prepare16_v3() with the
...
extra prepFlags argument. Add the SQLITE_PREPARE_PERSISTENT option as one
bit in that argument.
FossilOrigin-Name: 4a25c5883380fe5990d8180adb58c3bdc7a3d081bc4c69cd4de3cd57074fb251
2017-06-01 00:54:35 +00:00
drh
2ab792e4c0
Change sqlite3BtreeNext() and sqlite3BtreePrevious() so that they return
...
SQLITE_DONE if they have already reached the end (or beginning) of the table.
This gives a performance increase and size reduction.
FossilOrigin-Name: e972a3860892022d57b26ec44ce0fbadc61c1ff54b7a10b7e82390db88d323a7
2017-05-30 18:34:07 +00:00
drh
7a6ea93fd8
Do not expose the name of the internal Mem object in the public interface
...
defined by sqlite3.h.
FossilOrigin-Name: 19dd753f9e50fee247b1ab141669817c7e88bc3f6d6065dba6c731db9f7a2409
2017-04-09 19:23:55 +00:00
drh
ab087d4e67
Fix the OP_Once opcode so that it works correctly for recursive triggers.
...
Ticket [06796225f59c057cd120f1].
FossilOrigin-Name: 2556014514f36808e6d18b25722eae0daeeb8fbb5d18af13a9698ea6c6db1679
2017-03-24 17:59:56 +00:00
drh
585ce1923c
Experimental enhancement to automatically trim NULL values from the end of
...
records, for a reduced disk footprint. This change also involves increasing
the P5 operand from 8 to 16 bits.
FossilOrigin-Name: 118ded403b95050b74ae2b03919c43d614094a32
2017-01-25 14:58:27 +00:00
dan
9e1ab1a8a4
Ensure that sqlite3_column_count() returns 0 for the "set" mode of "get/set"
...
PRAGMA statements that do not return a value in that case (e.g. page_size,
cache_size, auto_vacuum).
FossilOrigin-Name: 5c05d8ec5e895661dae2de30c73dfdeaff93511e
2017-01-05 19:32:48 +00:00
drh
a582b01698
Simplifications to the way UnpackedRecord objects are allocated. Smaller
...
and faster code that also fixes a subtle (currently unreachable) bug.
FossilOrigin-Name: f7ab01f254cd9d7006b8dec29adb234a671b8e6f
2016-12-21 19:45:54 +00:00
drh
f14b7fb73b
Add the sqlite3VdbeAppendP4() method for adding P4 content to the most recently
...
coded instruction.
FossilOrigin-Name: 28883e8f3e92a8015fb5f6c8ae8580833931543d
2016-12-07 21:35:55 +00:00
drh
861b1307cb
The use P4_DYNAMIC in place of the P4_MPRINTF operand type.
...
FossilOrigin-Name: 3954f83798ed78527280c9db6360c62a5134b9ec
2016-12-07 20:22:31 +00:00
drh
9e5eb9c8cc
Revise the implementation of OP_Once so that it is smaller, faster, and uses
...
less memory. This also fixes an obscure bug introduced 3 days ago by check-in
[5990a1bdb4a073].
FossilOrigin-Name: 6bf5ba10d28f1b0a32aa9a560ae3143a1235eadb
2016-09-18 16:08:10 +00:00
drh
43f58d6a17
Fix various internal #defines to conform to new C-language naming restrictions,
...
specifically that private-use macros names must not begin with "_".
FossilOrigin-Name: 5471aca0158851d3fb0a2517306917536deb38bb
2016-07-09 16:14:45 +00:00
drh
7cc84c2cdd
Remove the VdbeOp.opflags field and its associated initialization overhead.
...
Update mkopcodeh.tcl to reorder opcode numbers to help the resolveP2Values()
routine run faster.
FossilOrigin-Name: 099478fa7521ba52262ef2bf24dd8f0114ce92e1
2016-04-11 13:36:42 +00:00
drh
dbf8a16cb3
Merge 3.12.0 beta changes from trunk.
...
FossilOrigin-Name: 3296a0ceedef43c2790f0b36471f91138a575243
2016-03-21 15:32:19 +00:00
drh
f71a366407
Some pragmas can be reused without an automatic reprepare.
...
FossilOrigin-Name: db1ce7e13e656fcd2766f1b1f225cbfefe8f73ad
2016-03-16 20:44:45 +00:00
drh
1a606f8246
Merge enhancements and fixes from trunk.
...
FossilOrigin-Name: f040a5bb62f3473fba6450c97c68f538d1df21ef
2016-02-09 15:44:18 +00:00
drh
2fade2f791
Make sure every co-routines has its own set of temporary registers and does
...
not share temporaries, since a co-routine might expect the content of a
temporary register to be preserved across an OP_Yield.
Proposed fix for ticket [d06a25c84454a].
FossilOrigin-Name: ca72be8618e5d466d6f35819ca8bbd2b84269959
2016-02-09 02:12:20 +00:00
drh
20f272c96f
Merge recent enhancements from trunk.
...
FossilOrigin-Name: 327af5f644a49b2f41d5456958f9d61a2b704e1c
2016-01-20 11:33:37 +00:00
drh
dad300d8e1
Fix a problem with SQLITE_TEST_REALLOC_STRESS.
...
FossilOrigin-Name: 0aaf3febb00f622c5ef0853b2491d69f7ca7a21e
2016-01-18 00:20:26 +00:00
drh
2ce1865dd8
Improvements to the way sqlite3VdbeAddOpList() works, resulting in a slightly
...
smaller and faster binary.
FossilOrigin-Name: 88ceb588bcdb3ca86d0c58cfdeb61b5fe070872f
2016-01-16 20:50:21 +00:00
drh
d286b9fb7d
Merge all the latest enhancements from trunk.
...
FossilOrigin-Name: 395a153ff7b3c7a72f3d02b6fe76d72383f4e480
2015-10-30 16:50:00 +00:00
drh
6b86881788
Merge recent trunk enhancements.
...
FossilOrigin-Name: 6a513c05850949900f396c7a61accb97cc6d2af5
2015-09-03 14:48:25 +00:00
drh
163c29c5f3
Merge enhancements from trunk.
...
FossilOrigin-Name: 25ee3000e94d60d8c1d7b980f416dcc33eb11105
2015-09-03 14:39:33 +00:00
drh
076e85f59c
Add the sqlite3VdbeLoadString() and sqlite3VdbeMultiLoad() routines to help
...
with code generation, especially on PRAGMAs. Rename sqlite3VdbeAddGoto()
to just sqlite3VdbeGoto().
FossilOrigin-Name: 847387ec8e6fef283899578fb232b2c23b00ee5b
2015-09-03 13:46:12 +00:00
drh
0ff287fb01
Add and use the sqlite3VdbeChangeOpcode() routine. Simplify the implementation
...
of the other sqlite3VdbeChange*() routines.
FossilOrigin-Name: 0a5b00e493efae58252f9fc7bde5a469645942d5
2015-09-02 18:40:33 +00:00
drh
2991ba050b
Add the sqlite3VdbeAddGoto(v,i) routine as a shorthand for
...
sqlite3VdbeAddOp2(v,OP_Goto,0,i).
FossilOrigin-Name: be78f413df1b0d874b44a866ef6bf17543d7e8a2
2015-09-02 18:19:00 +00:00
drh
bec2476afc
Merge in all the trunk changes from the previous year. This breaks the
...
cursor-hint mechanism, but provides a baseline for trouble-shooting.
FossilOrigin-Name: 82a7a61bc0883b1e7432548e4890791717aa1bb3
2015-08-13 20:07:13 +00:00
drh
59b4bd4840
Merge all the latest enhancements from trunk. This merge include FTS5
...
and a number of notable performance enhancements.
FossilOrigin-Name: 39936b33b0668aad81aa574d4d74c92b0ddd218a
2015-06-30 16:29:59 +00:00
drh
9c7c913cd6
Cache the sqlite3_context structure in the P4 operand of VDBE programs
...
for faster SQL function dispatch.
FossilOrigin-Name: 2abc44eb3b9d489321baa50bc25e17dafbda3687
2015-06-26 18:16:52 +00:00
drh
5600329bc0
Merge all recent enhancements and fixes from trunk.
...
FossilOrigin-Name: 199bfb67fdf642cca6cd5d460fa4dc602b94837a
2015-06-17 18:18:51 +00:00
drh
97bae794c2
Add a new opcode to the VDBE that gives the b-tree a hint about the set
...
of columns in a table or index that are actually used by the query.
FossilOrigin-Name: f167bba446b78dd7538d0b2bae3e6678f3b1ba28
2015-06-05 15:59:57 +00:00
drh
df3c171881
Merge all recent trunk enhancements into the sessions branch.
...
FossilOrigin-Name: 5f14f34f072921e229bc20a5185c0cdb3f464c04
2015-04-12 01:33:37 +00:00
dan
7004f3f6a3
Improve performance of multi-field sorts where the first field has a low cardinality.
...
FossilOrigin-Name: 601e7b6b8e6bfabda03b70f75094c9014e3a3c49
2015-03-30 12:06:26 +00:00
drh
04e8a58669
Merge recent trunk enhancements, including the read-after-ROLLBACK change
...
and the addition of sqlite3_stmt_scanstatus() support, as well as various
minor bug fixes.
FossilOrigin-Name: f09055f3c4348264c7336f90646375f0d98b061e
2014-11-18 21:20:57 +00:00
drh
518140ed04
Change the SQLITE_SCANSTAT_EST parameter so that it returns a double for
...
the estimated number of output rows per loop, rather than a 64-bit integer.
Revise the output format for the ".scanstats on" in the shell to make use
of this new capability.
FossilOrigin-Name: f9684000665ae7ef6f89c3773612b8286b8f545a
2014-11-06 03:55:10 +00:00
dan
037b5324bd
Remove unused variable from struct WhereInfo. Add some explanatory comments to new code.
...
FossilOrigin-Name: f5313e0c680d9baebefb1cf50ddadedd4418a334
2014-11-03 11:25:32 +00:00
dan
6f9702ed4d
If SQLITE_ENABLE_STMT_SCANSTATUS is defined, record the number of times each VDBE opcode is executed. Derive the values returned by sqlite3_stmt_scanstatus() from these records on demand.
...
FossilOrigin-Name: 9ea37422a8cc2fce51bb10508e5e90f40fd4b511
2014-11-01 20:38:06 +00:00
dan
04489b6dce
Add the experimental sqlite3_stmt_scanstatus() API.
...
FossilOrigin-Name: 6a9bab34aeb6a01b612211a28c140de60a3e883c
2014-10-31 20:11:32 +00:00
drh
6b011d83b4
Merge all recent trunk changes into the sessions branch.
...
FossilOrigin-Name: 6406b77f2c447751a2fbb16f01c61cdcfd6af59e
2014-09-21 22:49:20 +00:00
drh
75179ded97
Reduce the number of arguments to RecordCompare functions from 4 to 3,
...
resulting in a small performance increase.
FossilOrigin-Name: 8239c35aedd583af79505378bb7dbb78346a3f45
2014-09-16 14:37:35 +00:00
drh
f257b4c613
Merge the latest trunk enhancements into the sessions branch.
...
FossilOrigin-Name: a5d94eaba6aa12ff16d2a0af2fc752bcdb461877
2014-06-30 20:02:55 +00:00
drh
3eddb23e31
Change the VDBE to export the sqlite3MemCompare() routine and thus free
...
where.c from the dependency on vdbeInt.h.
FossilOrigin-Name: d186d1ac3c47f0d814636c4b8386a6065a294750
2014-06-28 14:28:06 +00:00