aboutsummaryrefslogtreecommitdiff
path: root/test/existsfault.test
diff options
context:
space:
mode:
authordrh <>2021-05-04 12:07:16 +0000
committerdrh <>2021-05-04 12:07:16 +0000
commit433a3e935de3d4dbfe81e7626e7d511ae3700e1b (patch)
tree64dba3b597679260e81c8c6bfa182870dc78d0a4 /test/existsfault.test
parentf83d501c6dd1e7a5f41c698576e21fb3a15bf454 (diff)
downloadsqlite-433a3e935de3d4dbfe81e7626e7d511ae3700e1b.tar.gz
sqlite-433a3e935de3d4dbfe81e7626e7d511ae3700e1b.zip
Back out the EXISTS-to-IN optimization. It slows things down rather than
speeds them up depending on the query. And (see [forum:/forumpost/8692d94725|forum post 8692d94725]) it sometimes results in an incorrect answer. We may come back and revisit this optimization later, but for now it seems best just to disable it. FossilOrigin-Name: 16252d73fa73569fd7506676f6ffbbcd43addfb105384fb74449d30ca720904a
Diffstat (limited to 'test/existsfault.test')
-rw-r--r--test/existsfault.test51
1 files changed, 0 insertions, 51 deletions
diff --git a/test/existsfault.test b/test/existsfault.test
deleted file mode 100644
index 4a33eeb35..000000000
--- a/test/existsfault.test
+++ /dev/null
@@ -1,51 +0,0 @@
-# 2021 January 15
-#
-# 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.
-#
-#***********************************************************************
-# This file implements regression tests for SQLite library. The
-# focus of this file is testing cases where EXISTS expressions are
-# transformed to IN() expressions by where.c
-#
-
-set testdir [file dirname $argv0]
-source $testdir/tester.tcl
-set testprefix existsfault
-
-do_execsql_test 1 {
- CREATE TABLE t1(a PRIMARY KEY, b);
- INSERT INTO t1 VALUES(1, 'one');
- INSERT INTO t1 VALUES(2, 'two');
- INSERT INTO t1 VALUES(3, 'three');
- INSERT INTO t1 VALUES(4, 'four');
- INSERT INTO t1 VALUES(5, 'five');
- INSERT INTO t1 VALUES(6, 'six');
- INSERT INTO t1 VALUES(7, 'seven');
-
- CREATE TABLE t2(c INTEGER, d INTEGER);
- INSERT INTO t2 VALUES(1, 1);
- INSERT INTO t2 VALUES(3, 2);
- INSERT INTO t2 VALUES(5, 3);
- INSERT INTO t2 VALUES(7, 4);
-}
-faultsim_save_and_close
-
-do_faultsim_test 1 -prep {
- faultsim_restore_and_reopen
-} -body {
- execsql {
- SELECT t1.* FROM t1 WHERE EXISTS(
- SELECT * FROM t2 WHERE t2.c=t1.a AND d IN (1, 2, 3)
- )
- }
-} -test {
- faultsim_test_result {0 {1 one 3 three 5 five}}
-}
-
-
-finish_test