---
This commit is contained in:
@@ -0,0 +1,92 @@
|
||||
## Summary
|
||||
<!--Explain briefly what goes wrong and explain why you believe this is a bug and not the intended behavior of SQLite (if it is not a crash).-->**No review yet**
|
||||
|
||||
## Minimized query
|
||||
|
||||
```sql
|
||||
CREATE TABLE T (
|
||||
a INTEGER,
|
||||
b REAL,
|
||||
c REAL
|
||||
);
|
||||
INSERT INTO T VALUES (1,2.0,10.5), (1,-3.5,20.25), (2,9e999,-1.0);
|
||||
WITH d AS (SELECT a,SUM(b*c) AS e FROM T GROUP BY a) SELECT * FROM d;
|
||||
.save
|
||||
PRAGMA index_info(idx1);
|
||||
PRAGMA wal_checkpoint('RESTART');
|
||||
PRAGMA encoding = 'UTF-16le';
|
||||
.shell
|
||||
CREATE TABLE t1(c, b, a, PRIMARY KEY(b, a)) WITHOUT ROWID;
|
||||
INSERT INTO t1 VALUES(zeroblob(like('0', hex(NULL))), (CAST(--(-(1)) AS DATE) + 2), 3), (4, 5, 6);
|
||||
ALTER TABLE t1 DROP c;
|
||||
CREATE TABLE x1234(a, b, c PRIMARY KEY) WITHOUT ROWID;
|
||||
CREATE INDEX i1 ON x1234(b) WHERE ((a+5) % 10)==0;
|
||||
|
||||
WITH _m AS MATERIALIZED (SELECT * FROM x1234) SELECT * FROM _m AS a FULL JOIN t1 AS b ON a.rowid = b.rowid;
|
||||
DROP INDEX IF EXISTS x1234;
|
||||
WITH cte AS (SELECT * FROM x1234 WHERE EXISTS (SELECT 1 FROM x1234 WHERE b > 0)) SELECT * FROM cte;
|
||||
VACUUM main;
|
||||
DELETE FROM t1 WHERE a > (SELECT AVG(a) FROM t1) RETURNING *;
|
||||
SELECT RANK() OVER (PARTITION BY b ORDER BY b ROWS BETWEEN CURRENT ROW AND UNBOUNDED FOLLOWING EXCLUDE GROUP) FROM x1234;
|
||||
INSERT INTO x1234 DEFAULT VALUES;
|
||||
SELECT COUNT(*) FILTER (WHERE c IS NOT NULL), SUM(rowid) FILTER (WHERE c > 0), COUNT(*) FILTER (WHERE 1=0), COUNT(*) FILTER (WHERE 1=1), COUNT(*) FILTER (WHERE NULL), AVG(c) FILTER (WHERE c > 0 AND c < 100), COUNT(*) FILTER (WHERE typeof(c) = "text") FROM x1234;
|
||||
```
|
||||
|
||||
## Actual output
|
||||
|
||||
```sql
|
||||
Usage: /home/test/sqlite3-src/build/sqlite3 [OPTIONS] FILENAME [SQL]
|
||||
FILENAME is the name of an SQLite database. A new database is created
|
||||
if the file does not previously exist.
|
||||
OPTIONS include:
|
||||
-append append the database to the end of the file
|
||||
-ascii set output mode to 'ascii'
|
||||
-bail stop after hitting an error
|
||||
-batch force batch I/O
|
||||
-box set output mode to 'box'
|
||||
-column set output mode to 'column'
|
||||
-cmd COMMAND run "COMMAND" before reading stdin
|
||||
-csv set output mode to 'csv'
|
||||
-deserialize open the database using sqlite3_deserialize()
|
||||
-echo print commands before execution
|
||||
-init FILENAME read/process named file
|
||||
-[no]header turn headers on or off
|
||||
-help show this message
|
||||
-html set output mode to HTML
|
||||
-interactive force interactive I/O
|
||||
-json set output mode to 'json'
|
||||
-line set output mode to 'line'
|
||||
-list set output mode to 'list'
|
||||
-lookaside SIZE N use N entries of SZ bytes for lookaside memory
|
||||
-markdown set output mode to 'markdown'
|
||||
-maxsize N maximum size for a --deserialize database
|
||||
-memtrace trace all memory allocations and deallocations
|
||||
-mmap N default mmap size set to N
|
||||
-newline SEP set output row separator. Default: '\n'
|
||||
-nofollow refuse to open symbolic links to database files
|
||||
-nonce STRING set the safe-mode escape nonce
|
||||
-nullvalue TEXT set text string for NULL values. Default ''
|
||||
-pagecache SIZE N use N slots of SZ bytes each for page cache memory
|
||||
-quote set output mode to 'quote'
|
||||
-readonly open the database read-only
|
||||
-safe enable safe-mode
|
||||
-separator SEP set output column separator. Default: '|'
|
||||
-stats print memory stats before each finalize
|
||||
-table set output mode to 'table'
|
||||
-tabs set output mode to 'tabs'
|
||||
-version show SQLite version
|
||||
-vfs NAME use NAME as the default VFS
|
||||
```
|
||||
|
||||
## Expectation
|
||||
|
||||
```sql
|
||||
|
||||
```
|
||||
|
||||
## Flag
|
||||
|
||||
```
|
||||
-help
|
||||
```
|
||||
|
||||
Reference in New Issue
Block a user