0
0
mirror of https://github.com/tursodatabase/libsql.git synced 2024-12-15 22:39:05 +00:00
libsql/libsql-wal/tests/assets/fixtures/tkt-a8a0d2996a.test
ad hoc ad79ef48a2
libsql wal tests (#1408)
* add tests

* add bench
2024-05-24 13:59:17 +00:00

71 lines
1.3 KiB
Plaintext

CREATE TABLE t(x,y);
INSERT INTO t VALUES('1','1');
SELECT typeof(x), typeof(y) FROM t WHERE 1=x+0 AND y=='1';
SELECT typeof(x), typeof(y) FROM t WHERE 1=x-0 AND y=='1';
SELECT typeof(x), typeof(y) FROM t WHERE 1=x*1 AND y=='1';
SELECT typeof(x), typeof(y) FROM t WHERE 1=x/1 AND y=='1';
SELECT typeof(x), typeof(y) FROM t WHERE 1=x%4 AND y=='1';
UPDATE t SET x='1xyzzy';
SELECT typeof(x), typeof(y) FROM t WHERE 1=x+0 AND y=='1';
SELECT typeof(x), typeof(y) FROM t WHERE 1=x-0 AND y=='1';
SELECT typeof(x), typeof(y) FROM t WHERE 1=x*1 AND y=='1';
SELECT typeof(x), typeof(y) FROM t WHERE 1=x/1 AND y=='1';
SELECT typeof(x), typeof(y) FROM t WHERE 1=x%4 AND y=='1';
UPDATE t SET x='1.0';
SELECT typeof(x), typeof(y) FROM t WHERE 1=x+0 AND y=='1';
SELECT typeof(x), typeof(y) FROM t WHERE 1=x-0 AND y=='1';
SELECT typeof(x), typeof(y) FROM t WHERE 1=x*1 AND y=='1';
SELECT typeof(x), typeof(y) FROM t WHERE 1=x/1 AND y=='1';
SELECT typeof(x), typeof(y) FROM t WHERE 1=x%4 AND y=='1';
SELECT 1+1.;
SELECT '1.23e64'/'1.0000e+62';
SELECT '100x'+'-2y';
SELECT '100x'+'4.5y';
SELECT '-9223372036854775807x'-'1x';
SELECT '9223372036854775806x'+'1x';
SELECT '1234x'/'10y', '1234x'/'10.y', '1234x'/'1e1y';