==== affinity2-100 CREATE TABLE t1( xi INTEGER, xr REAL, xb BLOB, xn NUMERIC, xt TEXT ); INSERT INTO t1(rowid,xi,xr,xb,xn,xt) VALUES(1,1,1,1,1,1); INSERT INTO t1(rowid,xi,xr,xb,xn,xt) VALUES(2,'2','2','2','2','2'); INSERT INTO t1(rowid,xi,xr,xb,xn,xt) VALUES(3,'03','03','03','03','03'); ---- stmt 0 ok stmt 94 err 1 -1 154 no such table: t1 stmt 154 err 1 -1 224 no such table: t1 stmt 224 err 1 -1 299 no such table: t1 ==== affinity2-110 SELECT xi, typeof(xi) FROM t1 ORDER BY rowid; ---- stmt 0 err 1 -1 48 no such table: t1 ==== affinity2-120 SELECT xr, typeof(xr) FROM t1 ORDER BY rowid; ---- stmt 0 err 1 -1 48 no such table: t1 ==== affinity2-130 SELECT xb, typeof(xb) FROM t1 ORDER BY rowid; ---- stmt 0 err 1 -1 48 no such table: t1 ==== affinity2-140 SELECT xn, typeof(xn) FROM t1 ORDER BY rowid; ---- stmt 0 err 1 -1 48 no such table: t1 ==== affinity2-150 SELECT xt, typeof(xt) FROM t1 ORDER BY rowid; ---- stmt 0 err 1 -1 48 no such table: t1 ==== affinity2-200 SELECT rowid, xi==xt, xi==xb, xi==+xt FROM t1 ORDER BY rowid; ---- stmt 0 err 1 -1 64 no such table: t1 ==== affinity2-210 SELECT rowid, xr==xt, xr==xb, xr==+xt FROM t1 ORDER BY rowid; ---- stmt 0 err 1 -1 64 no such table: t1 ==== affinity2-220 SELECT rowid, xn==xt, xn==xb, xn==+xt FROM t1 ORDER BY rowid; ---- stmt 0 err 1 -1 64 no such table: t1 ==== affinity2-300 SELECT rowid, xt==+xi, xt==xi, xt==xb FROM t1 ORDER BY rowid; ---- stmt 0 err 1 -1 64 no such table: t1 ==== 400 CREATE TABLE ttt(c0, c1); CREATE INDEX ii ON ttt(CAST(c0 AS NUMERIC)); INSERT INTO ttt VALUES('abc', '-1'); ---- stmt 0 ok stmt 28 err 1 -1 75 no such table: main.ttt stmt 75 err 1 -1 115 no such table: ttt ==== 410 SELECT * FROM ttt WHERE CAST(c0 AS NUMERIC) > c1 GROUP BY rowid; ---- stmt 0 err 1 -1 67 no such table: ttt ==== 420 SELECT * FROM ttt INDEXED BY ii WHERE CAST(c0 AS NUMERIC) > c1 GROUP BY rowid; ---- stmt 0 err 1 -1 81 no such table: ttt ==== 430 CREATE TABLE t3(a, b, c INTEGER); CREATE INDEX t3ac ON t3(a, c-1); INSERT INTO t3 VALUES(1, 1, 1); INSERT INTO t3 VALUES(2, 1, 0); INSERT INTO t3 VALUES(3, 1, 1); INSERT INTO t3 VALUES(4, 1, 0); INSERT INTO t3 VALUES(5, 1, 1); ---- stmt 0 ok stmt 36 err 1 -1 71 no such table: main.t3 stmt 71 err 1 -1 105 no such table: t3 stmt 105 err 1 -1 139 no such table: t3 stmt 139 err 1 -1 173 no such table: t3 stmt 173 err 1 -1 207 no such table: t3 stmt 207 err 1 -1 241 no such table: t3 ==== 440 SELECT * FROM t3 WHERE c='0' ORDER BY a; ---- stmt 0 err 1 -1 43 no such table: t3 ==== 500 DROP TABLE IF EXISTS t0; CREATE TABLE t0(c0 TEXT UNIQUE, c1); INSERT INTO t0(c0) VALUES (-1); SELECT quote(- x'ce'), quote(t0.c0), quote(- x'ce' >= t0.c0) FROM t0; ---- stmt 0 ok stmt 27 ok stmt 66 err 1 -1 100 no such table: t0 stmt 100 err 1 -1 172 no such table: t0 ==== 501 SELECT * FROM t0 WHERE - x'ce' >= t0.c0; ---- stmt 0 err 1 -1 43 no such table: t0 ==== 502 SELECT quote(+-+x'ce'), quote(t0.c0), quote(+-+x'ce' >= t0.c0) FROM t0; ---- stmt 0 err 1 -1 74 no such table: t0 ==== 503 SELECT * FROM t0 WHERE +-+x'ce' >= t0.c0; ---- stmt 0 err 1 -1 44 no such table: t0 ==== 504 SELECT quote(- 'ce'), quote(t0.c0), quote(- 'ce' >= t0.c0) FROM t0; ---- stmt 0 err 1 -1 70 no such table: t0 ==== 505 SELECT * FROM t0 WHERE - 'ce' >= t0.c0; ---- stmt 0 err 1 -1 42 no such table: t0 ==== 506 SELECT quote(+-+'ce'), quote(t0.c0), quote(+-+'ce' >= t0.c0) FROM t0; ---- stmt 0 err 1 -1 72 no such table: t0 ==== 507 SELECT * FROM t0 WHERE +-+'ce' >= t0.c0; ---- stmt 0 err 1 -1 43 no such table: t0 ==== 600 DROP TABLE IF EXISTS t0; CREATE TABLE t0(c0 REAL UNIQUE); INSERT INTO t0(c0) VALUES (3175546974276630385); SELECT 3175546974276630385 < c0 FROM t0; ---- stmt 0 ok stmt 29 ok stmt 66 err 1 -1 119 no such table: t0 stmt 119 err 1 -1 164 no such table: t0 ==== 601 SELECT 1 FROM t0 WHERE 3175546974276630385 < c0; ---- stmt 0 err 1 -1 53 no such table: t0