/ Check-in [6bc37297]
Login

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

Overview
Comment:Omit a couple of test cases if the library is compiled without subqueries. (CVS 2488)
Downloads: Tarball | ZIP archive | SQL archive
Timelines: family | ancestors | descendants | both | trunk
Files: files | file ages | folders
SHA1:6bc372978364a1a4bfa14732a818a6bba613b1e3
User & Date: danielk1977 2005-05-29 14:23:13
Context
2005-06-06
14:45
Fix a bug in the malloc2 tests introduced by checkin (2473). (CVS 2489) check-in: fafaa18e user: drh tags: trunk
2005-05-29
14:23
Omit a couple of test cases if the library is compiled without subqueries. (CVS 2488) check-in: 6bc37297 user: danielk1977 tags: trunk
2005-05-27
09:41
Minor changes to help build and test SSE. (CVS 2487) check-in: 3ac4a212 user: danielk1977 tags: trunk
Changes
Hide Diffs Unified Diffs Ignore Whitespace Patch

Changes to test/insert.test.

7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
...
342
343
344
345
346
347
348

349
350
351
352
353

354
355
356
357
358
#    May you find forgiveness for yourself and forgive others.
#    May you share freely, never taking more than you give.
#
#***********************************************************************
# This file implements regression tests for SQLite library.  The
# focus of this file is testing the INSERT statement.
#
# $Id: insert.test,v 1.25 2005/03/29 03:11:00 danielk1977 Exp $

set testdir [file dirname $argv0]
source $testdir/tester.tcl

# Try to insert into a non-existant table.
#
do_test insert-1.1 {
................................................................................
  }
} {1 2 2}

# Ticket #1140:  Check for an infinite loop in the algorithm that tests
# to see if the right-hand side of an INSERT...SELECT references the left-hand
# side.
#

do_test insert-8.1 {
  execsql {
    INSERT INTO t3 SELECT * FROM (SELECT * FROM t3 UNION ALL SELECT 1,2,3)
  }
} {}



integrity_check insert-99.0

finish_test







|







 







>
|
|
|
|
|
>





7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
...
342
343
344
345
346
347
348
349
350
351
352
353
354
355
356
357
358
359
360
#    May you find forgiveness for yourself and forgive others.
#    May you share freely, never taking more than you give.
#
#***********************************************************************
# This file implements regression tests for SQLite library.  The
# focus of this file is testing the INSERT statement.
#
# $Id: insert.test,v 1.26 2005/05/29 14:23:13 danielk1977 Exp $

set testdir [file dirname $argv0]
source $testdir/tester.tcl

# Try to insert into a non-existant table.
#
do_test insert-1.1 {
................................................................................
  }
} {1 2 2}

# Ticket #1140:  Check for an infinite loop in the algorithm that tests
# to see if the right-hand side of an INSERT...SELECT references the left-hand
# side.
#
ifcapable subquery {
  do_test insert-8.1 {
    execsql {
      INSERT INTO t3 SELECT * FROM (SELECT * FROM t3 UNION ALL SELECT 1,2,3)
    }
  } {}
}


integrity_check insert-99.0

finish_test

Changes to test/insert2.test.

8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
...
255
256
257
258
259
260
261

262
263
264
265
266
267

268
269
270
#    May you share freely, never taking more than you give.
#
#***********************************************************************
# This file implements regression tests for SQLite library.  The
# focus of this file is testing the INSERT statement that takes is
# result from a SELECT.
#
# $Id: insert2.test,v 1.16 2005/03/29 03:11:00 danielk1977 Exp $

set testdir [file dirname $argv0]
source $testdir/tester.tcl

# Create some tables with data that we can select against
#
do_test insert2-1.0 {
................................................................................
    CREATE TABLE t2(a, b);
    INSERT INTO t2 VALUES(1, 2);
    CREATE INDEX t2i1 ON t2(a);
    INSERT INTO t2 SELECT a, 3 FROM t2 WHERE a = 1;
    SELECT * FROM t2;
  }
} {1 2 1 3}

do_test insert2-5.2 {
  execsql {
    INSERT INTO t2 SELECT (SELECT a FROM t2), 4;
    SELECT * FROM t2;
  }
} {1 2 1 3 1 4}


finish_test








|







 







>
|
|
|
|
|
|
>



8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
...
255
256
257
258
259
260
261
262
263
264
265
266
267
268
269
270
271
272
#    May you share freely, never taking more than you give.
#
#***********************************************************************
# This file implements regression tests for SQLite library.  The
# focus of this file is testing the INSERT statement that takes is
# result from a SELECT.
#
# $Id: insert2.test,v 1.17 2005/05/29 14:23:13 danielk1977 Exp $

set testdir [file dirname $argv0]
source $testdir/tester.tcl

# Create some tables with data that we can select against
#
do_test insert2-1.0 {
................................................................................
    CREATE TABLE t2(a, b);
    INSERT INTO t2 VALUES(1, 2);
    CREATE INDEX t2i1 ON t2(a);
    INSERT INTO t2 SELECT a, 3 FROM t2 WHERE a = 1;
    SELECT * FROM t2;
  }
} {1 2 1 3}
ifcapable subquery {
  do_test insert2-5.2 {
    execsql {
      INSERT INTO t2 SELECT (SELECT a FROM t2), 4;
      SELECT * FROM t2;
    }
  } {1 2 1 3 1 4}
}

finish_test