mirror of
https://github.com/tursodatabase/libsql.git
synced 2024-12-15 09:49:40 +00:00
ad79ef48a2
* add tests * add bench
22 lines
724 B
Plaintext
22 lines
724 B
Plaintext
|
|
CREATE TABLE sqliteDemo(a);
|
|
INSERT INTO sqliteDemo(a) VALUES(1),(2),(3),(4),(5);
|
|
CREATE TABLE SQLiteDemo2(a INTEGER PRIMARY KEY AUTOINCREMENT);
|
|
INSERT INTO SQLiteDemo2 SELECT * FROM sqliteDemo;
|
|
CREATE TABLE t1(b);
|
|
INSERT INTO t1(b) SELECT a FROM sqliteDemo;
|
|
ANALYZE;
|
|
SELECT tbl FROM sqlite_stat1 WHERE idx IS NULL ORDER BY tbl;
|
|
|
|
|
|
CREATE TABLE t1(a INTEGER PRIMARY KEY, b INTEGER);
|
|
INSERT INTO t1 VALUES(1, 7223372036854775);
|
|
INSERT INTO t1 VALUES(2, 7223372036854776);
|
|
INSERT INTO t1 VALUES(3, 7223372036854777);
|
|
CREATE INDEX i1 ON t1(b);
|
|
ANALYZE;
|
|
UPDATE sqlite_stat4 SET sample = substr(sample, 0, 4);
|
|
ANALYZE sqlite_schema;
|
|
SELECT * FROM t1 WHERE b>7223372036854775
|
|
|