Many hyperlinks are disabled.
Use anonymous login
to enable hyperlinks.
Overview
Comment: | Add new tests to show that journal_mode=OFF works with locking_mode=EXCLUSIVE as long as the journal_mode is set prior to the first transaction. Ticket #3811. (CVS 6525) |
---|---|
Downloads: | Tarball | ZIP archive |
Timelines: | family | ancestors | descendants | both | trunk |
Files: | files | file ages | folders |
SHA1: |
e62ac26f72224a4ba6c7dc5c32b7e437 |
User & Date: | drh 2009-04-20 13:32:33.000 |
Context
2009-04-20
| ||
17:43 | Change the journal_mode pragma so that it always returns the current journal mode, even on a failed attempt to change the journal mode. Allow the journal mode to be changed as long as there is not a pending transaction. Ticket #3811. (CVS 6526) (check-in: 419e320ae5 user: drh tags: trunk) | |
13:32 | Add new tests to show that journal_mode=OFF works with locking_mode=EXCLUSIVE as long as the journal_mode is set prior to the first transaction. Ticket #3811. (CVS 6525) (check-in: e62ac26f72 user: drh tags: trunk) | |
12:31 | Clarify the documentation to make it clear that sqlite3_interrupt() does not effect new SQL statements that are started after the running statement count reaches zero. Ticket #3815. (CVS 6524) (check-in: 3182e8bf69 user: drh tags: trunk) | |
Changes
Added test/jrnlmode3.test.
> > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > | 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 61 62 63 64 65 66 67 68 69 70 | # 2009 April 20 # # The author disclaims copyright to this source code. In place of # a legal notice, here is a blessing: # # May you do good and not evil. # May you find forgiveness for yourself and forgive others. # May you share freely, never taking more than you give. # #*********************************************************************** # # $Id: jrnlmode3.test,v 1.4 2009/04/20 13:32:33 drh Exp $ set testdir [file dirname $argv0] source $testdir/tester.tcl ifcapable {!pager_pragmas} { finish_test return } # Ticket #3811 # # Verify that journal_mode=OFF works as long as it occurs before the first # transaction, even if locking_mode=EXCLUSIVE is enabled. The behavior if # journal_mode is changed after the first transaction is undefined and hence # untested. # do_test jrnlmode3-1.1 { db eval { PRAGMA journal_mode=OFF; PRAGMA locking_mode=EXCLUSIVE; CREATE TABLE t1(x); INSERT INTO t1 VALUES(1); SELECT * FROM t1; } } {off exclusive 1} do_test jrnlmode3-1.2 { db eval { BEGIN; INSERT INTO t1 VALUES(2); ROLLBACK; SELECT * FROM t1; } } {1 2} db close file delete -force test.db test.db-journal sqlite3 db test.db do_test jrnlmode3-2.1 { db eval { PRAGMA locking_mode=EXCLUSIVE; PRAGMA journal_mode=OFF; CREATE TABLE t1(x); INSERT INTO t1 VALUES(1); SELECT * FROM t1; } } {exclusive off 1} do_test jrnlmode3-2.2 { db eval { BEGIN; INSERT INTO t1 VALUES(2); ROLLBACK; SELECT * FROM t1; } } {1 2} finish_test |