Many hyperlinks are disabled.
Use anonymous login
to enable hyperlinks.
Overview
Comment: | Add tests to create and drop a virtual table during a recursive call from an application-defined function. Ticket #3080. (CVS 5061) |
---|---|
Downloads: | Tarball | ZIP archive |
Timelines: | family | ancestors | descendants | both | trunk |
Files: | files | file ages | folders |
SHA1: |
d4d6eff353edd5680776436ab3406227 |
User & Date: | drh 2008-04-28 17:12:11.000 |
Context
2008-04-28
| ||
17:41 | Modified Varint32 functions to disable code for single-byte handling as it is already handled by their respective macro forms. (CVS 5062) (check-in: be10f5dda6 user: shane tags: trunk) | |
17:12 | Add tests to create and drop a virtual table during a recursive call from an application-defined function. Ticket #3080. (CVS 5061) (check-in: d4d6eff353 user: drh tags: trunk) | |
16:55 | Change the implementation of the NaN recognition to be more cross-platform. Ticket #3089. (CVS 5060) (check-in: 07fd9a8c6c user: drh tags: trunk) | |
Changes
Added test/tkt3080.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 71 72 73 74 75 76 77 | # 2008 April 27 # # 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. # #*********************************************************************** # # Ticket #3080 # # Make sure that application-defined functions are able to recursively # invoke SQL statements that create and drop virtual tables. # # $Id: tkt3080.test,v 1.1 2008/04/28 17:12:11 drh Exp $ # set testdir [file dirname $argv0] source $testdir/tester.tcl do_test tkt3080.1 { db function execsql execsql db eval { SELECT execsql('CREATE TABLE t1(x)'); } execsql {SELECT name FROM sqlite_master} } {t1} do_test tkt3080.2 { db eval { INSERT INTO t1 VALUES('CREATE TABLE t2(y);'); SELECT execsql(x) FROM t1; } db eval { SELECT name FROM sqlite_master; } } {t1 t2} do_test tkt3080.3 { execsql { INSERT INTO t1 VALUES('CREATE TABLE t3(z); DROP TABLE t3;'); } catchsql { SELECT execsql(x) FROM t1 WHERE rowid=2; } } {1 {database table is locked}} do_test tkt3080.4 { db eval { SELECT name FROM sqlite_master; } } {t1 t2} ifcapable vtab { register_echo_module [sqlite3_connection_pointer db] do_test tkt3080.10 { set sql { CREATE VIRTUAL TABLE t4 USING echo(t2); INSERT INTO t4 VALUES(123); DROP TABLE t4; } execsql { DELETE FROM t1; INSERT INTO t1 VALUES($sql); } db eval { SELECT execsql(x) FROM t1 } execsql {SELECT name FROM sqlite_master} } {t1 t2} do_test tkt3080.11 { execsql {SELECT * FROM t2} } {123} } finish_test |