drh
9715f7f033
Fix a bug in the 'start of ...' date/time modifiers when they follow a
...
julian day number. Fix for ticket [6097cb92745327a1].
FossilOrigin-Name: 081dbcfb6d82528cefecb36c4491fa6e1a790b17
2017-03-02 23:40:21 +00:00
dan
1d62a66230
Fix another RBU case similar to the previous. This one for systems where the
...
sector-size is larger than the page-size.
FossilOrigin-Name: 4012bb3aa91927156ba149caa4e5c622b0729d79
2017-03-02 16:56:48 +00:00
dan
cb1b0a693a
When saving the state of an RBU update in the incremental-checkpoint phase,
...
sync the database file. Otherwise, if a power failure occurs and the RBU
update resumed following system recovery, the database may become corrupt.
FossilOrigin-Name: edee6a80e1cc7e6a2b8c3c7f76dd794fc8ab9a72
2017-03-02 14:51:47 +00:00
drh
1cfaf8eafb
Add an optional bitmask of allowed optimizations on the "PRAGMA optimize"
...
command. The 0x01 bit is Debug Mode.
FossilOrigin-Name: a35388eef4096c1856b025dbd90143409d4a72d3
2017-03-02 14:17:21 +00:00
drh
8d990b34db
Merge recent trunk enhancements.
...
FossilOrigin-Name: c60cdb47612c05c252613e50a8ac10635469fdfe
2017-03-02 13:22:04 +00:00
drh
76adb23980
Make sure the Vdbe.expmask value is set correctly in sqlite3VdbeSwap().
...
This fixes a problem introduced by [a8fd7052].
FossilOrigin-Name: 29f54b899e5cf22ece98ab41c39c41d75a4b228d
2017-03-02 13:13:30 +00:00
dan
2147221c36
Fix a use-after-free problem in the shell tool code that could occur if an SQL
...
statement were executed after an ".open" command with invalid options.
FossilOrigin-Name: ac760db0727209db0a816e112ea5f47e54d54dac
2017-03-01 11:30:27 +00:00
mistachkin
6e5688d375
Make PATH handling more robust in the batch tools for MSVC.
...
FossilOrigin-Name: 23a8917e848a999533bc66467f7cb2f4f3d45bc1
2017-02-27 17:16:27 +00:00
dan
81415257ec
Improve performance of fts5 writes by writing the "averages" record once at
...
the end of each transaction instead of every time the table is updated.
FossilOrigin-Name: 2b210d691462b463796e7948399133c296e89ebf
2017-02-27 17:06:56 +00:00
dan
8a89d834d6
Add an sqlite3_set_last_insert_rowid() method. Use it to work around fts4 and
...
fts5 modifying the last-insert-rowid unintuitively from within commit
processing.
FossilOrigin-Name: 952a3906b30a818e4574bb85f57150577d04f74e
2017-02-27 16:15:29 +00:00
dan
9c58b63c18
Add an sqlite3_set_last_insert_rowid() method. Use it to work around fts4 and
...
fts5 modifying the last-insert-rowid unintuitively from within commit
processing.
FossilOrigin-Name: fe41bb5632a5d438acfd682809f1bd12315b970a
2017-02-27 14:52:48 +00:00
dan
2efd3488ba
Remove references to special handling in virtual table methods from the
...
documentation for sqlite3_last_insert_rowid().
FossilOrigin-Name: 660f9569d76e4ff1f5bd4f37f640e6a4fc2cf87d
2017-02-27 12:23:52 +00:00
dan
70cdf38232
Add an 'extern "C"' block to header file sqlite3userauth.h.
...
FossilOrigin-Name: ffd61fb449a510b2fc90caf86b266733051cc365
2017-02-25 20:57:46 +00:00
dan
5328181db1
Optimize defragmentPage() in the case where the page contains either one or
...
two free-blocks and a small number of fragmented bytes.
FossilOrigin-Name: 4cd2a9672c59ea4b3b4cf3d2f139af3c18a8e833
2017-02-25 17:47:31 +00:00
dan
3b2ede1f03
Tweak the code on this branch to detect b-tree page corruption in the same cases as the trunk.
...
FossilOrigin-Name: f9863b39d96dce6cb5e49a5f3a445ff3d897a951
2017-02-25 16:24:02 +00:00
dan
e6d065a81e
Optimize defragmentPage() in the case where the page contains either one or
...
two free-blocks and a small number of fragmented bytes.
FossilOrigin-Name: 202b1c0276aec6b8da64d3277de1ad91c9d62d80
2017-02-24 19:58:22 +00:00
dan
bda4cb876c
Save a few bytes and a few cycles by setting Vdbe.expmask to zero for
...
statements prepared using legacy interface sqlite3_prepare().
FossilOrigin-Name: a8fd705258643863493476f8b42ee981608a339f
2017-02-23 16:30:16 +00:00
drh
555227bec0
Add two NEVER() operators in the sqlite3BtreeRowCountEst() routine.
...
FossilOrigin-Name: 7a959f6d1ea038988cdb4c02d6f37abaec2580a0
2017-02-23 02:15:33 +00:00
drh
bce0414844
Do a single OP_Expire at the very end of "PRAGMA optimize", and omit the
...
OP_Expire on ANALYZE commands invoked by the pragma.
FossilOrigin-Name: 188300a337c87b7ee0dd1f4b9a4f1bd80e70cca4
2017-02-23 00:58:36 +00:00
drh
2ead47cb49
Change the name of the analyze_as_needed pragma to "optimize". Enhance the
...
comment (which will become documentation, assuming these changes land on trunk)
to explain that the optimize pragma is likely to be enhanced in various ways
in future releases and that applications should not depend upon the current
behavior.
FossilOrigin-Name: 9fced545a6f80c55d6dc4a6106cb2d3569566b3e
2017-02-22 20:24:10 +00:00
drh
114ce7a4b1
Merge integrity_check and other improvements from trunk.
...
FossilOrigin-Name: fe073905081b421405ca425ca03c5b8b0ff5f2c8
2017-02-22 19:49:54 +00:00
dan
24d772cc27
Move a branch condition in analyze.c inside an #ifdef SQLITE_ENABLE_STAT4 block.
...
FossilOrigin-Name: d6afd98de3ee8b714dfd6477ead955096f623972
2017-02-22 19:41:16 +00:00
dan
bd1d270ec9
Improve the performance of ANALYZE when SQLITE_ENABLE_STAT4 is defined.
...
FossilOrigin-Name: 737a82444065752785c643b1d29ca097c828effb
2017-02-22 19:27:51 +00:00
drh
6bd166b81e
Improvements to PRAGMA integrity_check.
...
Verify CHECK constraints.
Verify NOT NULL constraints even on table that lack indexes.
Verify CHECK and NOT NULL constraints with PRAGMA quick_check.
FossilOrigin-Name: aa02bd3c95e374008b930d296c88dfafaf11c65a
2017-02-22 18:53:13 +00:00
drh
66accfc56b
Cleanup and simplification of the output row count limit control of
...
PRAGMA integrity_check.
FossilOrigin-Name: 5af7d72ed9ec758283d78ceb46627d72021c1c60
2017-02-22 18:04:42 +00:00
drh
8b174f2916
Fix integrity_check so that it verifies NOT NULL constraints even for tables
...
that have no indexes. Enhance quick_check so that it verifies NOT NULL and
CHECK constraints.
FossilOrigin-Name: 5264844b069cdc20f456acee9f5b2b97c986120d
2017-02-22 15:11:36 +00:00
drh
8a284dcefe
Enhance "PRAGMA integrity_check" so that it verifies CHECK constraints.
...
FossilOrigin-Name: 549bae0856004ff65b505175460abd598b30fe57
2017-02-22 14:15:37 +00:00
dan
1325adf5e9
In sqlite3VdbeHalt(), return as soon as possible if
...
Vdbe.magic!=VDBE_MAGIC_RUN. This makes sqlite3_reset() slightly faster in some
cases.
FossilOrigin-Name: 80adc0cb4ed7bacc54b15ac8b5b205403939c8c4
2017-02-21 21:24:05 +00:00
dan
f0e808c60b
Fix an FTS5 problem that could cause a crash when certain queries were
...
interrupted using sqlite3_interrupt().
FossilOrigin-Name: e400909f313c317b7b67be6eb867ed61df7383dc
2017-02-21 17:52:58 +00:00
drh
e324782254
Very small enhancement to dispatch speed for SQL functions.
...
FossilOrigin-Name: 3c3228ed16ed8a72630bd56bb9192ee3c7f82093
2017-02-21 15:27:22 +00:00
mistachkin
4689956b9e
Correct a harmless typo in the previous check-in.
...
FossilOrigin-Name: 1589db012ef1389bf84399fccf96d143b2ac4c0f
2017-02-20 23:32:04 +00:00
mistachkin
5e6710ab65
Avoid unsigned integer overflows for SQLITE_WIN32_HEAP_INIT_SIZE when the Win32 heap subsystem is used with very large values of SQLITE_DEFAULT_CACHE_SIZE and/or SQLITE_DEFAULT_PAGE_SIZE.
...
FossilOrigin-Name: 96b6a98e5e4cb0ddbfcd78b05bfbfcd8976e9f32
2017-02-20 19:13:37 +00:00
drh
7e84b377a9
Small grammar simplification.
...
FossilOrigin-Name: 0d8a868acd74fb1d076f23fda58b841bb7e6900b
2017-02-20 14:30:17 +00:00
drh
ad67e66dca
Merge fixes from trunk.
...
FossilOrigin-Name: ff213f2ef5bf96754a2264685d25546d8b5ccf0a
2017-02-20 13:11:07 +00:00
drh
99d5b4cde6
Updated comments. No code changes.
...
FossilOrigin-Name: e842ad391e62df273a5b1ed569d42ea46d03a99b
2017-02-18 22:52:40 +00:00
drh
4a54bb5794
Add the OP_SqlExec opcode and use it to implement "PRAGMA analyze_as_needed",
...
invoking ANALYZE subcommands as necessary. This simplifies the implementation.
FossilOrigin-Name: d386015f5e7ecdd951d70db56b7bbd858be7ad90
2017-02-18 15:58:52 +00:00
drh
eeea412a9d
Add the SQLITE_BUG_COMPATIBLE_20160819 compile-time option to omit the error
...
message when an unrecognized argument is provided to the VACUUM command.
FossilOrigin-Name: 491814272dce7e937b4734fcbc2ad69e12377b56
2017-02-18 13:47:11 +00:00
drh
dfe11bae99
Fix errors in the table resize detection.
...
FossilOrigin-Name: 4229caec0b60a1617b9d5ff94b47271cbd7be1e0
2017-02-18 02:42:54 +00:00
drh
182e84c116
In the analyze_as_needed pragma, avoid running unnecessary OP_LoadAnalysis
...
and OP_Expire opcodes. Make the analyze_as_needed pragma responsive to the
schema name.
FossilOrigin-Name: 882599a4a7ea92c9e7752e0745475508e58a11c3
2017-02-18 02:19:02 +00:00
drh
f196972c73
Fix the #endif location for an #ifndef SQLITE_UNTESTABLE macro in the
...
command-line shell.
FossilOrigin-Name: 8cc9d74c176a78aeebfbb39198c21b5dd547ff52
2017-02-17 23:52:00 +00:00
drh
5e98e838da
The analyze_as_needed pragma now responds to table size growth and will
...
automatically rerun the analysis after each 10x size increase.
FossilOrigin-Name: bfbdd07409688fac4ccddbab3639745f6152e23d
2017-02-17 19:24:06 +00:00
drh
72052a73a3
Add the "PRAGMA analyze_as_needed" command.
...
FossilOrigin-Name: e93db2373127d31d33ec46ef918fa9386bb664a6
2017-02-17 16:26:34 +00:00
drh
a3928dd7be
Set the TF_StatsUsed flag on tables when the query planner outcome is
...
affected by the sqlite_stat1 data. Also, change the column names of the
"PRAGMA stats" command so that they are not keywords.
FossilOrigin-Name: fb2b8ae8310e4ea4b42354bbf36c3084a9d5c6d7
2017-02-17 15:26:36 +00:00
drh
33bec3f5e8
Enhance the Index and Table objects so that they remember if their stats come
...
from the sqlite_stat1 table. Make the "PRAGMA stats" an SQLITE_DEBUG only
pragma. Add the flags column to "PRAGMA stats". These are all preliminary
steps toward a "PRAGMA analyze_ifneeded;" feature.
FossilOrigin-Name: 85026c8ee143bbd46565660fff8346ef81421546
2017-02-17 13:38:15 +00:00
drh
7898bfff26
Fix a test case that was made to fail by the LIKE optimization enhancement
...
in check-in [158290c0ab] but which went unnoticed because test builds were
running with ICU enabled and ICU disables the LIKE optimization.
FossilOrigin-Name: 218b2bbb0de07288889f6762d4461ea8acd78969
2017-02-17 02:04:31 +00:00
drh
2b44fd94ba
Enable the ".wheretrace" and ".selecttrace" extensions in the command-line
...
shell when compiled on Windows using DEBUG=3 or higher. Fix a harmless
warning in the shell that comes up when compiled this way.
FossilOrigin-Name: 8a03be1dc42737ba0712d33f639ea26dc243b20e
2017-02-17 01:43:51 +00:00
drh
e9ba910f0d
Change the name of WhereInfo.pDistinctSet to pResultSet, since it is now
...
used for more than just DISTINCT processing.
FossilOrigin-Name: 9fc5cd505fe6ab043519d68e999d2285e22452af
2017-02-16 20:52:52 +00:00
drh
5c258dc1cc
Change two MallocZero() calls into MallocRaw() to avoid unnecessary memset().
...
FossilOrigin-Name: ff5e733cbffd73faa4046e0f1c7f24bb6e131738
2017-02-16 17:18:07 +00:00
drh
c5f4816fc5
Fix a comment on a field of the ExprList object. No changes to code.
...
FossilOrigin-Name: bb8e264227175fc93f1c86a0083f8ad6c4ce2dc7
2017-02-16 16:26:53 +00:00
drh
6f271a421d
Increase Table.tabFlags from 8 to 32 bits.
...
FossilOrigin-Name: 7e14044c65f64322769bcad4640a5896be0a1687
2017-02-16 15:57:30 +00:00