drh
c7792fa052
Begin a series of changes designed to reduce the scope and frequency of
...
invalidating schemas. Design goals are that the internal schema should
never be deleted out from under a prepared statement that is running and
that all prepared statements should be expired if the schema is invalidated.
At the same time, minimize the number of schema invalidations. This change
merely revises the sqlite3ResetInternalSchema() function to use -1 as the
wildcard for "all" rather than 0, so that we can reset the main schema
independently of all the others.
FossilOrigin-Name: 6a8ad6e31e0d2b8a5ace38faf0efd805155ee5f3
2011-04-02 16:28:52 +00:00
drh
d50ffc416f
Fix additional cases of possible signed integer overflow, especially with
...
regard to negation.
FossilOrigin-Name: 2d5800bd8cfc7d7f5578a71b1aeaa74b2ec4b372
2011-03-08 02:38:28 +00:00
drh
30aa3b93b6
Cleanup to the OP_Checkpoint opcode.
...
FossilOrigin-Name: f611a5a879b7dec1ed1d8bf32413c8a6b81c3172
2011-02-07 23:56:01 +00:00
drh
87fa53ee8d
Merge in the blocking-checkpoint enhancement, including the new
...
sqlite3_wal_checkpoint_v2() interface and the
PRAGMA wal_checkpoint(full) statement.
FossilOrigin-Name: bac7342c368a7c4f5f2878e08d9581dcbf57dd58
2011-02-02 16:34:08 +00:00
drh
60ac3f426c
Fix the max_page_count pragma so that it will not set to a value smaller
...
than the current database size, as the documentation requires. Also,
remove all occurances of atoi() from the core.
FossilOrigin-Name: 2031974b606ef713b5f34522b2221470d98687c5
2010-11-23 18:59:27 +00:00
drh
27f9aba18c
Merge the checkpoint_fullfsync pragma and the superlock demonstration into
...
the checkpoint-v2 experimental branch.
FossilOrigin-Name: ebf74015f09fe241c1c6902dc8954f2b59ab41ec
2010-11-19 18:51:31 +00:00
drh
c97d84638e
Add the checkpoint_fullfsync pragma which enables F_FULLFSYNC on checkpoint
...
operations only, not during ordinary commit fsyncs.
FossilOrigin-Name: a069867301de3ca2e1753bd4d2e426d27365be4c
2010-11-19 18:23:35 +00:00
dan
cdc1f049bf
Modify the interface to the blocking wal-checkpoint functionality.
...
FossilOrigin-Name: 72787c010c8944e8fcf9c98aa4482f129142d8e9
2010-11-18 12:11:05 +00:00
dan
a58f26f93f
Add experimental command "PRAGMA wal_blocking_checkpoint", which uses the busy-handler to block until all readers have finished in order to ensure the next writer will be able to wrap around to the start of the log file.
...
FossilOrigin-Name: 7e3fc2c833a5baa08820c499867b6902bdc2ed5a
2010-11-16 18:56:51 +00:00
drh
9339da1f22
Rework the text to numeric conversion routines so that they work with either
...
UTF8 or UTF16 and do not require a NULL terminator. This allowed text to
numeric conversion without reallocating the string.
FossilOrigin-Name: 14eed3a0e0a45c6f2904a3a134aa27c159916f7b
2010-09-30 00:50:49 +00:00
drh
b975598ea0
Make sure all memory from sqlite3DbMalloc() is freed by sqlite3DbFree() and
...
all memory from sqlite3_malloc() is freed by sqlite3_free().
FossilOrigin-Name: ac1f37a647e9ed1c00a901d26d9956a86c40117a
2010-07-24 16:34:37 +00:00
drh
c6b2a0ff99
Change the journal_mode pragma to remove the "default journal mode" concept.
...
The journal_mode pragma only effects currently attached databases and does
not change the behavior of future attachments.
FossilOrigin-Name: e396184cd3bdb96e29ac33af5d1f631cac553341
2010-07-08 17:40:37 +00:00
drh
f77e2ac27d
Fix a compiler warning in PRAGMA journal_mode.
...
FossilOrigin-Name: d94269e60dbcb50b8a35f142c64ed013cc0045ac
2010-07-07 14:33:09 +00:00
dan
f6c614715c
Make sure the schema is loaded before preparing a "PRAGMA journal_mode" command. This helps it return meaningful results when it is the first command executed by a new database connection.
...
FossilOrigin-Name: ef126e775a02d69a9cab53028513e8799e1b6044
2010-07-07 13:54:28 +00:00
drh
3ebaee9633
The PRAGMA journal_mode=WAL; command now makes WAL the default journal mode
...
for new databases added with ATTACH, so the behavior is consistent with the
other journal modes.
FossilOrigin-Name: c3520460a4a39fc5e981c3033068ffbb422a4af2
2010-05-06 21:37:22 +00:00
dan
af0cfd366a
Have sqlite3_wal_checkpoint() handle a zero-length string in the same way as a NULL pointer. Fix "PRAGMA wal_checkpoint" so that it checkpoints all attached databases.
...
FossilOrigin-Name: 7fecd21f45b9ce773ffbcef6c84066474e8cd01c
2010-05-03 15:58:50 +00:00
drh
b033d8b9dc
Make sure the mutex is held while calling sqlite3ApiExit() in
...
sqlite3_wal_checkpoint(). Other cleanup of WAL logic.
FossilOrigin-Name: 11a85b821abff1ecb7ec8c37bc7783be9fc4ea6d
2010-05-03 13:37:30 +00:00
dan
5a299f9134
Add the "PRAGMA wal_autocheckpoint" command. Rename "PRAGMA checkpoint" to "PRAGMA wal_checkpoint".
...
FossilOrigin-Name: 714e5947264571386f966aa8fcdd5607b5832238
2010-05-03 11:05:08 +00:00
dan
586b9c8a94
Add the sqlite3_wal_checkpoint() and sqlite3_wal_autocheckpoint() APIs.
...
FossilOrigin-Name: 9803196dec85e3aa4105cc477e9cfe98d370e486
2010-05-03 08:04:49 +00:00
dan
5cf53537a8
Support compile-time option SQLITE_OMIT_WAL, for building without WAL support.
...
FossilOrigin-Name: 9b230c43dfa112e3e1589f9775926807bd36b36e
2010-05-01 16:40:20 +00:00
drh
29d4beccc0
Merge in recent changes from the trunk
...
FossilOrigin-Name: 7a0ac682c3bffcb345321fe97434563350ac90f9
2010-04-27 01:56:21 +00:00
drh
93791ea0ba
Change the default_cache_size pragma to always store a positive value.
...
FossilOrigin-Name: 36fb2cae75b5dfe1fe818895f03c0b4f4190a722
2010-04-26 17:36:35 +00:00
dan
e04dc88be5
Use the read and write version fields of the database header to mark a database as operating in wal-mode.
...
FossilOrigin-Name: 96bef18c1411c3e0348295886f105e1646c46320
2010-04-20 18:53:15 +00:00
dan
b9bf16bfde
Fixes for locking issues in WAL mode.
...
FossilOrigin-Name: a9617eff39177250e2f118f25fdd4b3acb8b0478
2010-04-14 11:23:30 +00:00
dan
f05c86dd73
Remove old code to interpret an argument (no longer used) to "PRAGMA checkpoint".
...
FossilOrigin-Name: 27dc5977c19e717afd65d3805557e38dec7bedcb
2010-04-13 11:56:03 +00:00
drh
63ca1dba52
Remove duplicate secure_delete pragma implemention.
...
FossilOrigin-Name: c15fda145b621fc86402914aa5b015e53590555a
2010-04-12 19:31:59 +00:00
dan
7c24610e64
Import experimental write-ahead-logging code.
...
FossilOrigin-Name: 409d61baeb0a19d1700c973f16c8acef7b8506cd
2010-04-12 19:00:29 +00:00
drh
c633908199
Wrap all automatic index changes inside SQLITE_OMIT_AUTOMATIC_INDEX. Add
...
the automatic_index PRAGMA to turn it on and off.
FossilOrigin-Name: a811a47fbe4f757a7ab575ae5a0f65177a3f07c0
2010-04-07 16:54:58 +00:00
drh
71caabf0cc
Remove the compile_option pragma (retaining compile_options - with an "s").
...
Updates to documentation.
FossilOrigin-Name: 733778df996a2dda7c31ff7b544cb6f9a6ed4c97
2010-02-26 15:39:24 +00:00
drh
264a2d4de1
Minor simplifications to the compile-time option reporting functions and
...
pragmas to facilitate coverage testing.
FossilOrigin-Name: 633d874783a94f923ff8240f9153764033d37a89
2010-02-25 15:28:41 +00:00
drh
4611d925a9
Expire pragma statements when reset, even if they were not run to completion.
...
FossilOrigin-Name: 78351d289bba83e536b64666c566b7bfc57351da
2010-02-25 14:47:01 +00:00
shaneh
dc97a8cdc1
Refactored compile time option diagnostic support to use strings identifiers instead of bitmask.
...
FossilOrigin-Name: 76a0294ab4208a0858a13bab0858e1bc1448b651
2010-02-23 20:08:35 +00:00
shaneh
ad9f9f6693
Consistent use of #ifdef for SQLITE_HAS_CODEC to avoid confusion.
...
FossilOrigin-Name: 34a3413a5318050254b246ad859c91c134516a32
2010-02-17 17:48:46 +00:00
drh
af034ed685
Enhancements to the secure_delete pragma to make it easier to use.
...
FossilOrigin-Name: 2bb38bb96ff6b9fb91dd1cf214041cf113ac5508
2010-02-12 19:46:26 +00:00
drh
5b47efa662
All the secure-delete setting to be changed at run-time using a pragma.
...
The SQLITE_SECURE_DELETE compile-time option determines the default setting.
FossilOrigin-Name: f72f8a870a0fc98a9f2b564ffafe7946bbce506e
2010-02-12 18:18:39 +00:00
shaneh
959dda6d94
Tweaks for consistency to the SEE and CEROD API declarations in sqlite3.h.
...
FossilOrigin-Name: 299f74567b1b97a1fdc0a620ef382cfd24941809
2010-01-28 19:56:27 +00:00
drh
07096f68ae
Move the query flattener turn-off from a pragma to an sqlite3_test_control()
...
call. Make provisions (not yet implemented) to turn off other optimizers
using the same call.
FossilOrigin-Name: 4a97c623f4e190134de4b2ca406e311034a74797
2009-12-22 23:52:32 +00:00
drh
7b688ede64
Add a pragma to disable the query flattener - for use during testing.
...
FossilOrigin-Name: 1d8550e5c88db0ea76aea579c1a5bf99d48fbe43
2009-12-22 00:29:53 +00:00
drh
91fc4a0c4d
Shift more OP_Found opcodes over to using the unpacked format, for improved
...
performance.
FossilOrigin-Name: 6705ab1ad12cbdbbcf1f3e5439a4e6cbdcc421b3
2009-11-12 20:39:03 +00:00
drh
8cff69df11
Enhance the OP_Found and OP_NotFound opcodes so that they can accept an
...
array of registers as an unpacked record in addition to a record built
using OP_MakeRecord. Use this to avoid OP_MakeRecord calls during IN
expression processing.
FossilOrigin-Name: b9eab885cd2ca1a1633329e7036c125e8dba62c5
2009-11-12 19:59:44 +00:00
drh
c81c11f62c
Remove the obsolete "$Id:$" RCS identifier strings from the source code.
...
FossilOrigin-Name: f6c045f649036958078cb15cd9d5453680c82b0c
2009-11-10 01:30:52 +00:00
dan
8099ce6f4a
Add missing comments to fkey.c. Also, change the terminology used for comments and names in fkey.c from "referenced/referencing" to "parent/child". This is arguably less correct, but is easier to follow.
...
FossilOrigin-Name: 540c2d18e14c277b55f95729fbafc04ca66466b2
2009-09-23 08:43:35 +00:00
dan
ba9108b84a
Fix compilation errors when OMIT_FOREIGN_KEY is defined.
...
FossilOrigin-Name: c447cb37d6439090eb08028d54a91d7d06043744
2009-09-22 07:13:42 +00:00
dan
75cbd984f7
Fix compilation with OMIT_TRIGGER defined. Ticket [1ff6d29030e9757d052af0f394e56bea96b8b59b|1ff6d29030].
...
FossilOrigin-Name: fb6ceed388f6d75bdc2ac2f43e5c98da74e2a448
2009-09-21 16:06:03 +00:00
dan
1da40a381f
Check in implementation of foreign key constraints.
...
FossilOrigin-Name: d5d399811876391642937edeb9e8434dd9e356f5
2009-09-19 17:00:31 +00:00
dan
5bde73c4eb
Change "PRAGMA disable_recursive_triggers" to "PRAGMA recursive_triggers". Also a fix for compiling with OMIT_TRIGGER defined.
...
FossilOrigin-Name: e016cca36390451d5d1c6e0d1b3cdbd6d869be1a
2009-09-01 17:11:07 +00:00
dan
76d462ee78
Fixes for new triggers scheme.
...
FossilOrigin-Name: 9eb91efda5241609ff18ff15ef5eaa0e86788eab
2009-08-30 11:42:51 +00:00
danielk1977
602b466e99
Cause opening a transaction on a sharable b-tree module automatically obtain a read-lock on page 1. This means there is no way for sqlite3BtreeGetMeta() to fail. (CVS 6836)
...
FossilOrigin-Name: e3c055f167f895ae45858de9d9d8a264df2f36b6
2009-07-02 07:47:33 +00:00
drh
8bfdf72136
Reorganize and cleanup the prepared statement object. Remove code that has
...
been commented out for ages and is no longer relevant to anything. (CVS 6786)
FossilOrigin-Name: 37ae5f5e8feb34a8e6e8b34aa18df1e9a1ce55cb
2009-06-19 14:06:03 +00:00
danielk1977
0d19f7ac57
Define a set of constants to use as the "index" argument to sqlite3BtreeGetMeta and UpdateMeta. This makes some parts of the code easier to follow. (CVS 6709)
...
FossilOrigin-Name: 6dbf4eca00f845baa7200aba421d0bc158ba96aa
2009-06-03 11:25:07 +00:00