/ Check-in [fd9c6ff0]
Login

Many hyperlinks are disabled.
Use anonymous login to enable hyperlinks.

Overview
Comment:Add test case to incrblob4.test. No changes to code.
Downloads: Tarball | ZIP archive | SQL archive
Timelines: family | ancestors | descendants | both | trunk
Files: files | file ages | folders
SHA1: fd9c6ff05f2052810549a1a6a384f4b40f4ba4ac
User & Date: dan 2016-10-20 11:48:48
Context
2016-10-21
10:09
If SQLITE_DIRECT_OVERFLOW_READ is defined at compile time, add "DIRECT_OVERFLOW_READ" to the list of symbols returned by "PRAGMA compile_options". check-in: b7d9727b user: dan tags: trunk
2016-10-20
11:48
Add test case to incrblob4.test. No changes to code. check-in: fd9c6ff0 user: dan tags: trunk
2016-10-18
16:36
Minor simplification of the comparison opcodes. check-in: 56474ebc user: drh tags: trunk
Changes
Hide Diffs Side-by-Side Diffs Ignore Whitespace Patch

Changes to test/incrblob4.test.

    82     82   do_test 3.3 {
    83     83     set new [string repeat % 900]
    84     84     execsql { UPDATE t1 SET v = $new WHERE k = 20 }
    85     85     execsql { DELETE FROM t1 WHERE k=19 }
    86     86     execsql { INSERT INTO t1(v) VALUES($new) }
    87     87   } {}
    88     88   
           89  +#-------------------------------------------------------------------------
           90  +# Test that it is not possible to DROP a table with an incremental blob
           91  +# cursor open on it.
           92  +#
           93  +do_execsql_test 4.1 {
           94  +  CREATE TABLE t2(a INTEGER PRIMARY KEY, b);
           95  +  INSERT INTO t2 VALUES(456, '0123456789');
           96  +}
           97  +do_test 4.2 {
           98  +  set blob [db incrblob -readonly t2 b 456]
           99  +  read $blob 5
          100  +} {01234}
          101  +do_catchsql_test 4.3 {
          102  +  DROP TABLE t2
          103  +} {1 {database table is locked}}
          104  +do_test 4.4 {
          105  +  sqlite3_extended_errcode db
          106  +} {SQLITE_LOCKED}
          107  +close $blob
          108  +
    89    109   finish_test
          110  +