Hi people,

I think I may have found a bug in v3.6.21 of Sqlite, but would someone be 
able to kindly verify my findings for me.

If I do the following...

CREATE TABLE t1 (c1 TEXT UNIQUE);
CREATE TABLE t2 (c2 TEXT UNIQUE);

INSERT INTO t1(c1) SELECT "a"
UNION ALL SELECT "b";

INSERT INTO t2(c2) SELECT "a"
UNION ALL SELECT "b"
UNION ALL SELECT "c"
UNION ALL SELECT "d"
UNION ALL SELECT "e";

SELECT t1.ROWID, t2.ROWID FROM t1, t2
WHERE (c1 = "a" AND c2 != "e")
OR (c1 = "b" AND c2 NOT IN ("a", "b", "c"));

then I get no rows returned.

However, if the table schema is changed to...

CREATE TABLE t1 (c1 TEXT);
CREATE TABLE t2 (c2 TEXT);

Then the select returns the following...

1|1
1|2
1|3
1|4
2|4
2|5

...which is as I would expect.

Is this a bug, or is it me?

Many, many thanks

Will
_______________________________________________
sqlite-users mailing list
sqlite-users@sqlite.org
http://sqlite.org:8080/cgi-bin/mailman/listinfo/sqlite-users

Reply via email to