/ Check-in [4f34d707]
Login
SQLite training in Houston TX on 2019-11-05 (details)
Part of the 2019 Tcl Conference

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

Overview
Comment:Add a test case for ticket [3557ad65a076c].
Downloads: Tarball | ZIP archive | SQL archive
Timelines: family | ancestors | descendants | both | trunk
Files: files | file ages | folders
SHA1: 4f34d7077b9acf7926c5e7375ca870d4ed3c60b9
User & Date: drh 2012-03-03 01:44:12
Context
2012-03-05
15:33
Merge the fts4-languageid branch with the trunk. check-in: 99a9073b user: dan tags: trunk
2012-03-03
01:44
Add a test case for ticket [3557ad65a076c]. check-in: 4f34d707 user: drh tags: trunk
00:34
Fix a bug [3557ad65a07] that causes incorrect DISTINCT processing on an indexed query involving the IN operator. check-in: dec9a995 user: drh tags: trunk
Changes
Hide Diffs Unified Diffs Ignore Whitespace Patch

Changes to test/select4.test.

801
802
803
804
805
806
807



















808
  catchsql {
    SELECT 1 UNION SELECT 2,3 UNION SELECT 4,5 ORDER BY 1;
  } db2
} {1 {SELECTs to the left and right of UNION do not have the same number of result columns}}

} ;# ifcapable compound




















finish_test







>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>

801
802
803
804
805
806
807
808
809
810
811
812
813
814
815
816
817
818
819
820
821
822
823
824
825
826
827
  catchsql {
    SELECT 1 UNION SELECT 2,3 UNION SELECT 4,5 ORDER BY 1;
  } db2
} {1 {SELECTs to the left and right of UNION do not have the same number of result columns}}

} ;# ifcapable compound


# Ticket [3557ad65a076c] - Incorrect DISTINCT processing with an
# indexed query using IN.
#
do_test select4-13.1 {
  sqlite3 db test.db
  db eval {
    CREATE TABLE t13(a,b);
    INSERT INTO t13 VALUES(1,1);
    INSERT INTO t13 VALUES(2,1);
    INSERT INTO t13 VALUES(3,1);
    INSERT INTO t13 VALUES(2,2);
    INSERT INTO t13 VALUES(3,2);
    INSERT INTO t13 VALUES(4,2);
    CREATE INDEX t13ab ON t13(a,b);
    SELECT DISTINCT b from t13 WHERE a IN (1,2,3);
  }
} {1 2}

finish_test