1
0
mirror of https://github.com/sqlite/sqlite.git synced 2025-07-29 08:01:23 +03:00

Tests for the subquery flattening fix of check-in (2987). (CVS 2988)

FossilOrigin-Name: 72a067f0df5818c0fdb3b9f8af20f83bb2e1dd34
This commit is contained in:
drh
2006-01-22 00:14:39 +00:00
parent ac83963afa
commit fe61378a22
3 changed files with 57 additions and 8 deletions

View File

@ -1,5 +1,5 @@
C Do\snot\sflatten\ssubqueries\sin\sa\sjoin\swhere\sthe\ssubquery\sincludes\sa\sLIMIT.\nTicket\s#1634.\s\sThis\sis\sjust\san\sinitial\sfix.\s\sMany\stest\scases\sneed\sto\sbe\nadded\sprior\sto\sclosing\sthe\sticket.\s(CVS\s2987) C Tests\sfor\sthe\ssubquery\sflattening\sfix\sof\scheck-in\s(2987).\s(CVS\s2988)
D 2006-01-21T22:19:55 D 2006-01-22T00:14:39
F Makefile.in ab3ffd8d469cef4477257169b82810030a6bb967 F Makefile.in ab3ffd8d469cef4477257169b82810030a6bb967
F Makefile.linux-gcc aee18d8a05546dcf1888bd4547e442008a49a092 F Makefile.linux-gcc aee18d8a05546dcf1888bd4547e442008a49a092
F README 9c4e2d6706bdcc3efdd773ce752a8cdab4f90028 F README 9c4e2d6706bdcc3efdd773ce752a8cdab4f90028
@ -223,7 +223,7 @@ F test/select2.test f3c2678c3a9f3cf08ec4988a3845bda64be6d9e3
F test/select3.test 8fece41cd8f2955131b3f973a7123bec60b6e65e F test/select3.test 8fece41cd8f2955131b3f973a7123bec60b6e65e
F test/select4.test c239f516aa31f42f2ef7c6d7cd01105f08f934ca F test/select4.test c239f516aa31f42f2ef7c6d7cd01105f08f934ca
F test/select5.test 0b47058d3e916c1fc9fe81f44b438e02bade21ce F test/select5.test 0b47058d3e916c1fc9fe81f44b438e02bade21ce
F test/select6.test f459a19bdac0501c4d3eb1a4df4b7a76f1bb8ad4 F test/select6.test 22f4b0c591b75464519ec5085b3385ac60698eb2
F test/select7.test 1bf795b948c133a15a2a5e99d3270e652ec58ce6 F test/select7.test 1bf795b948c133a15a2a5e99d3270e652ec58ce6
F test/server1.test e328b8e641ba8fe9273132cfef497383185dc1f5 F test/server1.test e328b8e641ba8fe9273132cfef497383185dc1f5
F test/shared.test 9982a65ccf3f4eee844a19f3ab0bcd7a158a76e5 F test/shared.test 9982a65ccf3f4eee844a19f3ab0bcd7a158a76e5
@ -344,7 +344,7 @@ F www/tclsqlite.tcl bb0d1357328a42b1993d78573e587c6dcbc964b9
F www/vdbe.tcl 87a31ace769f20d3627a64fa1fade7fed47b90d0 F www/vdbe.tcl 87a31ace769f20d3627a64fa1fade7fed47b90d0
F www/version3.tcl a99cf5f6d8bd4d5537584a2b342f0fb9fa601d8b F www/version3.tcl a99cf5f6d8bd4d5537584a2b342f0fb9fa601d8b
F www/whentouse.tcl 97e2b5cd296f7d8057e11f44427dea8a4c2db513 F www/whentouse.tcl 97e2b5cd296f7d8057e11f44427dea8a4c2db513
P 29725de474f9aec81cea0041d9ac2df932258d01 P af18c0f431a1a6349e40249009f2ac222f8c8114
R 155027f2bd0a2644348d1abb7c1fede1 R 038cd608b3bad3d890f2abe7363032af
U drh U drh
Z 52af4bf5dc7ce62a9ad3e0cb3c9897c9 Z 893a67daf028f983e2ed2caeaec7613b

View File

@ -1 +1 @@
af18c0f431a1a6349e40249009f2ac222f8c8114 72a067f0df5818c0fdb3b9f8af20f83bb2e1dd34

View File

@ -12,7 +12,7 @@
# focus of this file is testing SELECT statements that contain # focus of this file is testing SELECT statements that contain
# subqueries in their FROM clause. # subqueries in their FROM clause.
# #
# $Id: select6.test,v 1.21 2005/11/14 22:29:06 drh Exp $ # $Id: select6.test,v 1.22 2006/01/22 00:14:39 drh Exp $
set testdir [file dirname $argv0] set testdir [file dirname $argv0]
source $testdir/tester.tcl source $testdir/tester.tcl
@ -454,5 +454,54 @@ do_test select6-8.6 {
} {1} } {1}
} ;# ifcapable view } ;# ifcapable view
# Ticket #1634
#
do_test select6-9.1 {
execsql {
SELECT a.x, b.x FROM t1 AS a, (SELECT x FROM t1 LIMIT 2) AS b
}
} {1 1 1 2 2 1 2 2 3 1 3 2 4 1 4 2}
do_test select6-9.2 {
execsql {
SELECT x FROM (SELECT x FROM t1 LIMIT 2);
}
} {1 2}
do_test select6-9.3 {
execsql {
SELECT x FROM (SELECT x FROM t1 LIMIT 2 OFFSET 1);
}
} {2 3}
do_test select6-9.4 {
execsql {
SELECT x FROM (SELECT x FROM t1) LIMIT 2;
}
} {1 2}
do_test select6-9.5 {
execsql {
SELECT x FROM (SELECT x FROM t1) LIMIT 2 OFFSET 1;
}
} {2 3}
do_test select6-9.6 {
execsql {
SELECT x FROM (SELECT x FROM t1 LIMIT 2) LIMIT 3;
}
} {1 2}
do_test select6-9.7 {
execsql {
SELECT x FROM (SELECT x FROM t1 LIMIT -1) LIMIT 3;
}
} {1 2 3}
do_test select6-9.8 {
execsql {
SELECT x FROM (SELECT x FROM t1 LIMIT -1);
}
} {1 2 3 4}
do_test select6-9.9 {
execsql {
SELECT x FROM (SELECT x FROM t1 LIMIT -1 OFFSET 1);
}
} {2 3 4}
finish_test finish_test