## 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
BEGIN IMMEDIATE;
SAVEPOINT sp6990;
.changes on
PRAGMA busy_timeout = -9223372036854775809;
-- soundex({v})

ATTACH DATABASE ':memory:' AS aux19;
CREATE TABLE "T" (
  a INTEGER,
  b REAL
);
INSERT INTO T VALUES (-(-(-printf('%d', -(-(timediff(8696510444389118519, 8696510444389118519)))))),1.5), (2,-2.5), (3,0.0);
CREATE TABLE `t1`(a INTEGER PRIMARY KEY, b TEXT, c INT, d INT);
INSERT INTO t1 VALUES (1, 'Wernher', 10, 100);
INSERT INTO t1 VALUES (2, 'von', 20, 200);
INSERT INTO t1 VALUES (3, 'Braun', 30, 300);

CREATE INDEX t1bc ON t1(b, c);

PRAGMA writable_schema = ON;

.imposter t1bc t2

SELECT * FROM t2;

SELECT b, c FROM t1 ORDER BY b, c;

.quit
CREATE INDEX c
ON T(b);
SELECT * FROM T WHERE b >= -2.5 AND b < 2.0;
ANALYZE T;
WITH cte(a, b) AS (SELECT a, a FROM T) SELECT a, b FROM cte;
DROP TRIGGER IF EXISTS T;
SELECT * FROM T AS a LEFT OUTER JOIN T AS b ON a.rowid = b.rowid;
DETACH DATABASE aux19;
SELECT TOTAL(b) FROM T;
CREATE TRIGGER IF NOT EXISTS trg_T_5883 BEFORE INSERT ON T FOR EACH ROW BEGIN SELECT RAISE(ROLLBACK, 'rb'); END;
DELETE FROM t1 WHERE c IS NULL RETURNING *;
CREATE  VIEW IF NOT EXISTS v_T_4176 AS SELECT b FROM T;
SELECT GROUP_CONCAT(a) FROM T;
SELECT * FROM  t1;
ALTER TABLE t1 RENAME COLUMN c TO c_r5302;
REINDEX t1;
CREATE TEMPORARY  VIEW IF NOT EXISTS v_T_7903 AS SELECT a FROM T;
DELETE FROM T WHERE a IS NULL RETURNING *;
WITH cte AS (SELECT b, COUNT(*) AS cnt FROM t1 GROUP BY b) SELECT * FROM cte WHERE cnt > 1;
SELECT * FROM t1;
SELECT * FROM t1 WHERE EXISTS (SELECT 1 FROM t1 WHERE b < 0);
INSERT INTO t1 SELECT * FROM t1;
INSERT INTO T VALUES (1, NULL) ON CONFLICT(a) DO UPDATE SET a = excluded.a, b = excluded.b;
SELECT COUNT(*) FILTER (WHERE b IS NOT NULL), SUM(rowid) FILTER (WHERE b > 0), COUNT(*) FILTER (WHERE 1=0), COUNT(*) FILTER (WHERE 1=1), COUNT(*) FILTER (WHERE NULL), AVG(b) FILTER (WHERE b > 0 AND b < 100), COUNT(*) FILTER (WHERE typeof(b) = "text") FROM T;
INSERT INTO T DEFAULT VALUES;
ROLLBACK TO sp6990;
RELEASE sp6990;
creATE VIRTUAL TABLE t0 USING fts3("x", "y", "z");
DROP TABLE t0;
CREATE TRIGGER IF NOT EXISTS trg_T_2012 AFTER UPDATE OF a ON T BEGIN SELECT RAISE(FAIL, 'no'); END;
SELECT MIN(a) FROM T;
UPDATE t1 SET c = 'x';
SELECT AVG(a) FROM t1;

SELECT COUNT(*) FROM T;
DROP TRIGGER IF EXISTS t1;
SAVEPOINT sp6990;
.changes on
PRAGMA busy_timeout = 1.7976931348623157e+308;
-- soundex({v})

ATTACH DATABASE ':memory:' AS aux19;
CREATE TABLE "T" (
  a INTEGER,
  b REAL
);
INSERT INTO T VALUES (-(-(-printf('%d', -(-(timediff(8696510444389118519, 8696510444389118519)))))),1.5), (2,-2.5), (3,0.0);
CREATE TABLE `t1`(a INTEGER PRIMARY KEY, b TEXT, c INT, d INT);
INSERT INTO t1 VALUES (1, 'Wernher', 10, 100);
INSERT INTO t1 VALUES (2, 'von', 20, 200);
INSERT INTO t1 VALUES (3, 'Braun', 30, 300);

CREATE INDEX t1bc ON t1(b, c);

PRAGMA writable_schema = ON;

.imposter t1bc t2

SELECT * FROM t2;

SELECT b, c FROM t1 ORDER BY b, c;

.quit
CREATE INDEX c
ON T(b);
SELECT * FROM T WHERE b >= -2.5 AND b < 2.0;
ANALYZE T;
WITH cte(a, b) AS (SELECT a, a FROM T) SELECT a, b FROM cte;
DROP TRIGGER IF EXISTS T;
SELECT * FROM T AS a LEFT OUTER JOIN T AS b ON a.rowid = b.rowid;
DETACH DATABASE aux19;
SELECT TOTAL(b) FROM T;
CREATE TRIGGER IF NOT EXISTS trg_T_5883 BEFORE INSERT ON T FOR EACH ROW BEGIN SELECT RAISE(ROLLBACK, 'rb'); END;
DELETE FROM t1 WHERE c IS NULL RETURNING *;
CREATE  VIEW IF NOT EXISTS v_T_4176 AS SELECT b FROM T;
SELECT GROUP_CONCAT(a) FROM T;
SELECT * FROM  t1;
ALTER TABLE t1 RENAME COLUMN c TO c_r5302;
REINDEX t1;
CREATE TEMPORARY  VIEW IF NOT EXISTS v_T_7903 AS SELECT a FROM T;
DELETE FROM T WHERE a IS NULL RETURNING *;
WITH cte AS (SELECT b, COUNT(*) AS cnt FROM t1 GROUP BY b) SELECT * FROM cte WHERE cnt > 1;
SELECT * FROM t1;
SELECT * FROM t1 WHERE EXISTS (SELECT 1 FROM t1 WHERE b < 0);
INSERT INTO t1 SELECT * FROM t1;
INSERT INTO T VALUES (1, NULL) ON CONFLICT(a) DO UPDATE SET a = excluded.a, b = excluded.b;
SELECT COUNT(*) FILTER (WHERE b IS NOT NULL), SUM(rowid) FILTER (WHERE b > 0), COUNT(*) FILTER (WHERE 1=0), COUNT(*) FILTER (WHERE 1=1), COUNT(*) FILTER (WHERE NULL), AVG(b) FILTER (WHERE b > 0 AND b < 100), COUNT(*) FILTER (WHERE typeof(b) = "text") FROM T;
INSERT INTO T DEFAULT VALUES;
ROLLBACK TO sp6990;
RELEASE sp6990;
creATE VIRTUAL TABLE t0 USING fts3("x", "y", "z");
DROP TABLE t0;
CREATE TRIGGER IF NOT EXISTS trg_T_2012 AFTER UPDATE OF a ON T BEGIN SELECT RAISE(FAIL, 'no'); END;
SELECT MIN(a) FROM T;
UPDATE t1 SET c = 'x';
SELECT AVG(a) FROM t1;

SELECT COUNT(*) FROM T;
DROP TRIGGER IF EXISTS t1;
SAVEPOINT sp6990;
.changes on
PRAGMA busy_timeout = 1.7976931348623157e+308;
-- soundex({v})

ATTACH DATABASE ':memory:' AS aux19;
CREATE TABLE "T" (
  a INTEGER,
  b REAL
);
INSERT INTO T VALUES (-(-(-printf('%d', -(-(timediff(8696510444389118519, 8696510444389118519)))))),1.5), (2,-2.5), (3,0.0);
CREATE TABLE `t1`(a INTEGER PRIMARY KEY, b TEXT, c INT, d INT);
INSERT INTO t1 VALUES (1, 'Wernher', 10, 100);
INSERT INTO t1 VALUES (2, 'von', 20, 200);
INSERT INTO t1 VALUES (3, 'Braun', 30, 300);

CREATE INDEX t1bc ON t1(b, c);

PRAGMA writable_schema = ON;

.imposter t1bc t2

SELECT * FROM t2;

SELECT b, c FROM t1 ORDER BY b, c;

.quit
CREATE INDEX c
ON T(b);
SELECT * FROM T WHERE b >= -2.5 AND b < 2.0;
ANALYZE T;
WITH cte(a, b) AS (SELECT a, a FROM T) SELECT a, b FROM cte;
DROP TRIGGER IF EXISTS T;
SELECT * FROM T AS a LEFT OUTER JOIN T AS b ON a.rowid = b.rowid;
DETACH DATABASE aux19;
SELECT TOTAL(b) FROM T;
CREATE TRIGGER IF NOT EXISTS trg_T_5883 BEFORE INSERT ON T FOR EACH ROW BEGIN SELECT RAISE(ROLLBACK, 'rb'); END;
DELETE FROM t1 WHERE c IS NULL RETURNING *;
CREATE  VIEW IF NOT EXISTS v_T_4176 AS SELECT b FROM T;
SELECT GROUP_CONCAT(a) FROM T;
SELECT * FROM  t1;
ALTER TABLE t1 RENAME COLUMN c TO c_r5302;
REINDEX t1;
CREATE TEMPORARY  VIEW IF NOT EXISTS v_T_7903 AS SELECT a FROM T;
DELETE FROM T WHERE a IS NULL RETURNING *;
WITH cte AS (SELECT b, COUNT(*) AS cnt FROM t1 GROUP BY b) SELECT * FROM cte WHERE cnt > 1;
SELECT * FROM t1;
SELECT * FROM t1 WHERE EXISTS (SELECT 1 FROM t1 WHERE b < 0);
INSERT INTO t1 SELECT * FROM t1;
INSERT INTO T VALUES (1, NULL) ON CONFLICT(a) DO UPDATE SET a = excluded.a, b = excluded.b;
SELECT COUNT(*) FILTER (WHERE b IS NOT NULL), SUM(rowid) FILTER (WHERE b > 0), COUNT(*) FILTER (WHERE 1=0), COUNT(*) FILTER (WHERE 1=1), COUNT(*) FILTER (WHERE NULL), AVG(b) FILTER (WHERE b > 0 AND b < 100), COUNT(*) FILTER (WHERE typeof(b) = "text") FROM T;
INSERT INTO T DEFAULT VALUES;
ROLLBACK TO sp6990;
RELEASE sp6990;
creATE VIRTUAL TABLE t0 USING fts3("x", "y", "z");
DROP TABLE t0;
CREATE TRIGGER IF NOT EXISTS trg_T_2012 AFTER UPDATE OF a ON T BEGIN SELECT RAISE(FAIL, 'no'); END;
SELECT MIN(a) FROM T;
UPDATE t1 SET c = 'x';
SELECT AVG(a) FROM /* LAG({c}) */ t1;

SELECT COUNT(*) FROM T;
DROP TRIGGER IF EXISTS t1;
SAVEPOINT sp6990;
.changes on
PRAGMA busy_timeout = 1.7976931348623157e+308;
-- soundex({v})

ATTACH DATABASE ':memory:' AS aux19;
CREATE TABLE "T" (
  a INTEGER,
  b REAL
);
INSERT INTO T VALUES (-(-(-printf('%d', -(-(timediff(8696510444389118519, 8696510444389118519)))))),1.5), (2,-2.5), (3,0.0);
CREATE TABLE `t1`(a INTEGER PRIMARY KEY, b TEXT, c INT, d INT);
INSERT INTO t1 VALUES (1, 'Wernher', 10, 100);
INSERT INTO t1 VALUES (2, 'von', 20, 200);
INSERT INTO t1 VALUES (3, 'Braun', 30, 300);

CREATE INDEX t1bc ON t1(b, c);

PRAGMA writable_schema = ON;

.imposter t1bc t2

SELECT * FROM t2;

SELECT b, c FROM t1 ORDER BY b, c;

.quit
CREATE INDEX c
ON T(b);
SELECT * FROM T WHERE b >= -2.5 AND b < 2.0;
ANALYZE T;
WITH cte(a, b) AS (SELECT a, a FROM T) SELECT a, b FROM cte;
DROP TRIGGER IF EXISTS T;
SELECT * FROM T AS a LEFT OUTER JOIN T AS b ON a.rowid = b.rowid;
DETACH DATABASE aux19;
SELECT TOTAL(b) FROM T;
CREATE TRIGGER IF NOT EXISTS trg_T_5883 BEFORE INSERT ON T FOR EACH ROW BEGIN SELECT RAISE(ROLLBACK, 'rb'); END;
DELETE FROM t1 WHERE c IS NULL RETURNING *;
CREATE  VIEW IF NOT EXISTS v_T_4176 AS SELECT b FROM T;
SELECT GROUP_CONCAT(a) FROM T;
SELECT * FROM  t1;
ALTER TABLE t1 RENAME COLUMN c TO c_r5302;
REINDEX t1;
CREATE TEMPORARY  VIEW IF NOT EXISTS v_T_7903 AS SELECT a FROM T;
DELETE FROM T WHERE a IS NULL RETURNING *;
WITH cte AS (SELECT b, COUNT(*) AS cnt FROM t1 GROUP BY b) SELECT * FROM cte WHERE cnt > 1;
SELECT * FROM t1;
SELECT * FROM t1 WHERE EXISTS (SELECT 1 FROM t1 WHERE b < 0);
INSERT INTO t1 SELECT * FROM t1;
INSERT INTO T VALUES (1, NULL) ON CONFLICT(a) DO UPDATE SET a = excluded.a, b = excluded.b;
SELECT COUNT(*) FILTER (WHERE b IS NOT NULL), SUM(rowid) FILTER (WHERE b > 0), COUNT(*) FILTER (WHERE 1=0), COUNT(*) FILTER (WHERE 1=1), COUNT(*) FILTER (WHERE NULL), AVG(b) FILTER (WHERE b > 0 AND b < 100), COUNT(*) FILTER (WHERE typeof(b) = "text") FROM T;
INSERT INTO T DEFAULT VALUES;
ROLLBACK TO sp6990;
RELEASE sp6990;
creATE VIRTUAL TABLE t0 USING fts3("x", "y", "z");
DROP TABLE t0;
CREATE TRIGGER IF NOT EXISTS trg_T_2012 AFTER UPDATE OF a ON T BEGIN SELECT RAISE(FAIL, 'no'); END;
SELECT MIN(a) FROM T;
UPDATE t1 SET c = 'x';
SELECT AVG(a) FROM t1;

SELECT COUNT(*) FROM T;
DROP TRIGGER IF EXISTS t1;
SAVEPOINT sp6990;
.changes on
PRAGMA busy_timeout = 1.7976931348623157e+308;
-- soundex({v})

ATTACH DATABASE ':memory:' AS aux19;
CREATE TABLE "T" (
  a INTEGER,
  b REAL
);
INSERT INTO T VALUES (-(-(-printf('%d', -(-(timediff(8696510444389118519, 8696510444389118519)))))),1.5), (2,-2.5), (3,0.0);
CREATE TABLE `t1`(a INTEGER PRIMARY KEY, b TEXT, c INT, d INT);
INSERT INTO t1 VALUES (1, 'Wernher', 10, 100);
INSERT INTO t1 VALUES (2, 'von', 20, 200);
INSERT INTO t1 VALUES (3, 'Braun', 30, 300);

CREATE INDEX t1bc ON t1(b, c);

PRAGMA writable_schema = ON;

.imposter t1bc t2

SELECT * FROM t2;

SELECT b, c FROM t1 ORDER BY b, c;

.quit
CREATE INDEX c
ON T(b);
SELECT * FROM T WHERE b >= -2.5 AND b < 2.0;
ANALYZE T;
WITH cte(a, b) AS (SELECT a, a FROM T) SELECT a, b FROM cte;
DROP TRIGGER IF EXISTS T;
SELECT * FROM T AS a LEFT OUTER JOIN T AS b ON a.rowid = b.rowid;
DETACH DATABASE aux19;
SELECT TOTAL(b) FROM T;
CREATE TRIGGER IF NOT EXISTS trg_T_5883 BEFORE INSERT ON T FOR EACH ROW BEGIN SELECT RAISE(ROLLBACK, 'rb'); END;
DELETE FROM t1 WHERE c IS NULL RETURNING *;
CREATE  VIEW IF NOT EXISTS v_T_4176 AS SELECT b FROM T;
SELECT GROUP_CONCAT(a) FROM T;
SELECT * FROM  t1;
ALTER TABLE t1 RENAME COLUMN c TO c_r5302;
REINDEX t1;
CREATE TEMPORARY  VIEW IF NOT EXISTS v_T_7903 AS SELECT a FROM T;
DELETE FROM T WHERE a IS NULL RETURNING *;
WITH cte AS (SELECT b, COUNT(*) AS cnt FROM t1 GROUP BY b) SELECT * FROM cte WHERE cnt > 1;
SELECT * FROM t1;
SELECT * FROM t1 WHERE EXISTS (SELECT 1 FROM t1 WHERE b < 0);
INSERT INTO t1 SELECT * FROM t1;
INSERT INTO T VALUES (1, NULL) ON CONFLICT(a) DO UPDATE SET a = excluded.a, b = excluded.b;
SELECT COUNT(*) FILTER (WHERE b IS NOT NULL), SUM(rowid) FILTER (WHERE b > 0), COUNT(*) FILTER (WHERE 1=0), COUNT(*) FILTER (WHERE 1=1), COUNT(*) FILTER (WHERE NULL), AVG(b) FILTER (WHERE b > 0 AND b < 100), COUNT(*) FILTER (WHERE typeof(b) = "text") FROM T;
INSERT INTO T DEFAULT VALUES;
ROLLBACK TO sp6990;
RELEASE sp6990;
creATE VIRTUAL TABLE t0 USING fts3("x", "y", "z");
DROP TABLE t0;
CREATE TRIGGER IF NOT EXISTS trg_T_2012 AFTER UPDATE OF a ON T BEGIN SELECT RAISE(FAIL, 'no'); END;
SELECT MIN(a) FROM T;
UPDATE t1 SET c = 'x';
SELECT AVG(a) FROM t1;

SELECT COUNT(*) FROM T;
DROP TRIGGER IF EXISTS t1;
SAVEPOINT sp6990;
.changes on
PRAGMA busy_timeout = 1.7976931348623157e+308;
-- soundex({v})

ATTACH DATABASE ':memory:' AS aux19;
CREATE TABLE "T" (
  a INTEGER,
  b REAL
);
INSERT INTO T VALUES (-(-(-printf('%d', -(-(timediff(8696510444389118519, 8696510444389118519)))))),1.5), (2,-2.5), (3,0.0);
CREATE TABLE `t1`(a INTEGER PRIMARY KEY, b TEXT, c INT, d INT);
INSERT INTO t1 VALUES (1, 'Wernher', 10, 100);
INSERT INTO t1 VALUES (2, 'von', 20, 200);
INSERT INTO t1 VALUES (3, 'Braun', 30, 300);

CREATE INDEX t1bc ON t1(b, c);

PRAGMA writable_schema = ON;

.imposter t1bc t2

SELECT * FROM t2;

SELECT b, c FROM t1 ORDER BY b, c;

.quit
CREATE INDEX c
ON T(b);
SELECT * FROM T WHERE b >= -2.5 AND b < 2.0;
ANALYZE T;
WITH cte(a, b) AS (SELECT a, a FROM T) SELECT a, b FROM cte;
DROP TRIGGER IF EXISTS T;
SELECT * FROM T AS a LEFT OUTER JOIN T AS b ON a.rowid = b.rowid;
DETACH DATABASE aux19;
SELECT TOTAL(b) FROM T;
CREATE TRIGGER IF NOT EXISTS trg_T_5883 BEFORE INSERT ON T FOR EACH ROW BEGIN SELECT RAISE(ROLLBACK, 'rb'); END;
DELETE FROM t1 WHERE c IS NULL RETURNING *;
CREATE  VIEW IF NOT EXISTS v_T_4176 AS SELECT b FROM T;
SELECT GROUP_CONCAT(a) FROM T;
SELECT * FROM  t1;
ALTER TABLE t1 RENAME COLUMN c TO c_r5302;
REINDEX t1;
CREATE TEMPORARY  VIEW IF NOT EXISTS v_T_7903 AS SELECT a FROM T;
DELETE FROM T WHERE a IS NULL RETURNING *;
WITH cte AS (SELECT b, COUNT(*) AS cnt FROM t1 GROUP BY b) SELECT * FROM cte WHERE cnt > 1;
SELECT * FROM t1;
SELECT * FROM t1 WHERE EXISTS (SELECT 1 FROM t1 WHERE b < 0);
INSERT INTO t1 SELECT * FROM t1;
INSERT INTO T VALUES (1, NULL) ON CONFLICT(a) DO UPDATE SET a = excluded.a, b = excluded.b;
SELECT COUNT(*) FILTER (WHERE b IS NOT NULL), SUM(rowid) FILTER (WHERE b > 0), COUNT(*) FILTER (WHERE 1=0), COUNT(*) FILTER (WHERE 1=1), COUNT(*) FILTER (WHERE NULL), AVG(b) FILTER (WHERE b > 0 AND b < 100), COUNT(*) FILTER (WHERE typeof(b) = "text") FROM T;
INSERT INTO T DEFAULT VALUES;
ROLLBACK TO sp6990;
RELEASE sp6990;
creATE VIRTUAL TABLE t0 USING fts3("x", "y", "z");
DROP TABLE t0;
CREATE TRIGGER IF NOT EXISTS trg_T_2012 AFTER UPDATE OF a ON T BEGIN SELECT RAISE(FAIL, 'no'); END;
SELECT MIN(a) FROM T;
UPDATE t1 SET c = 'x';
SELECT AVG(a) FROM t1;

SELECT COUNT(*) FROM T;
DROP TRIGGER IF EXISTS t1;
SAVEPOINT sp6990;
.changes on
PRAGMA busy_timeout = 1.7976931348623157e+308;
-- soundex({v})

ATTACH DATABASE ':memory:' AS aux19;
CREATE TABLE "T" (
  a INTEGER,
  b REAL
);
INSERT INTO T VALUES (-(-(-printf('%d', -(-(timediff(8696510444389118519, 8696510444389118519)))))),1.5), (2,-2.5), (3,0.0);
CREATE TABLE `t1`(a INTEGER PRIMARY KEY, b TEXT, c INT, d INT);
INSERT INTO t1 VALUES (1, 'Wernher', 10, 100);
INSERT INTO t1 VALUES (2, 'von', 20, 200);
INSERT INTO t1 VALUES (3, 'Braun', 30, 300);

CREATE INDEX t1bc ON t1(b, c);

PRAGMA writable_schema = ON;

.imposter t1bc t2

SELECT * FROM t2;

SELECT b, c FROM t1 ORDER BY b, c;

.quit
CREATE INDEX c
ON T(b);
SELECT * FROM T WHERE b >= -2.5 AND b < 2.0;
ANALYZE T;
WITH cte(a, b) AS (SELECT a, a FROM T) SELECT a, b FROM cte;
DROP TRIGGER IF EXISTS T;
SELECT * FROM T AS a LEFT OUTER JOIN T AS b ON a.rowid = b.rowid;
DETACH DATABASE aux19;
SELECT TOTAL(b) FROM T;
CREATE TRIGGER IF NOT EXISTS trg_T_5883 BEFORE INSERT ON T FOR EACH ROW BEGIN SELECT RAISE(ROLLBACK, 'rb'); END;
DELETE FROM t1 WHERE c IS NULL RETURNING *;
CREATE  VIEW IF NOT EXISTS v_T_4176 AS SELECT b FROM T;
SELECT GROUP_CONCAT(a) FROM T;
SELECT * FROM  t1;
ALTER TABLE t1 RENAME COLUMN c TO c_r5302;
REINDEX t1;
CREATE TEMPORARY  VIEW IF NOT EXISTS v_T_7903 AS SELECT a FROM T;
DELETE FROM T WHERE a IS NULL RETURNING *;
WITH cte AS (SELECT b, COUNT(*) AS cnt FROM t1 GROUP BY b) SELECT * FROM cte WHERE cnt > 1;
SELECT * FROM t1;
SELECT * FROM t1 WHERE EXISTS (SELECT 1 FROM t1 WHERE b < 0);
INSERT INTO t1 SELECT * FROM t1;
INSERT INTO T VALUES (1, NULL) ON CONFLICT(a) DO UPDATE SET a = excluded.a, b = excluded.b;
SELECT COUNT(*) FILTER (WHERE b IS NOT NULL), SUM(rowid) FILTER (WHERE b > 0), COUNT(*) FILTER (WHERE 1=0), COUNT(*) FILTER (WHERE 1=1), COUNT(*) FILTER (WHERE NULL), AVG(b) FILTER (WHERE b > 0 AND b < 100), COUNT(*) FILTER (WHERE typeof(b) = "text") FROM T;
INSERT INTO T DEFAULT VALUES;
ROLLBACK TO sp6990;
RELEASE sp6990;
creATE VIRTUAL TABLE t0 USING fts3("x", "y", "z");
DROP TABLE t0;
CREATE TRIGGER IF NOT EXISTS trg_T_2012 AFTER UPDATE OF a ON T BEGIN SELECT RAISE(FAIL, 'no'); END;
SELECT MIN(a) FROM T;
UPDATE t1 SET c = 'x';
SELECT AVG(a) FROM t1;

SELECT COUNT(*) FROM T;
DROP TRIGGER IF EXISTS t1;
SAVEPOINT sp6990;
.changes on
PRAGMA busy_timeout = 1.7976931348623157e+308;
-- soundex({v})

ATTACH DATABASE ':memory:' AS aux19;
CREATE TABLE "T" (
  a INTEGER,
  b REAL
);
INSERT INTO T VALUES (-(-(-printf('%d', -(-(timediff(8696510444389118519, 8696510444389118519)))))),1.5), (2,-2.5), (3,0.0);
CREATE TABLE `t1`(a INTEGER PRIMARY KEY, b TEXT, c INT, d INT);
INSERT INTO t1 VALUES (1, 'Wernher', 10, 100);
INSERT INTO t1 VALUES (2, 'von', 20, 200);
INSERT INTO t1 VALUES (3, 'Braun', 30, 300);

CREATE INDEX t1bc ON t1(b, c);

PRAGMA writable_schema = ON;

.imposter t1bc t2

SELECT * FROM t2;

SELECT b, c FROM t1 ORDER BY b, c;

.quit
CREATE INDEX c
ON T(b);
SELECT * FROM T WHERE b >= -2.5 AND b < 2.0;
ANALYZE T;
WITH cte(a, b) AS (SELECT a, a FROM T) SELECT a, b FROM cte;
DROP TRIGGER IF EXISTS T;
SELECT * FROM T AS a LEFT OUTER JOIN T AS b ON a.rowid = b.rowid;
DETACH DATABASE aux19;
SELECT TOTAL(b) FROM T;
CREATE TRIGGER IF NOT EXISTS trg_T_5883 BEFORE INSERT ON T FOR EACH ROW BEGIN SELECT RAISE(ROLLBACK, 'rb'); END;
DELETE FROM t1 WHERE c IS NULL RETURNING *;
CREATE  VIEW IF NOT EXISTS v_T_4176 AS SELECT b FROM T;
SELECT GROUP_CONCAT(a) FROM T;
SELECT * FROM  t1;
ALTER TABLE t1 RENAME COLUMN c TO c_r5302;
REINDEX t1;
CREATE TEMPORARY  VIEW IF NOT EXISTS v_T_7903 AS SELECT a FROM T;
DELETE FROM T WHERE a IS NULL RETURNING *;
WITH cte AS (SELECT b, COUNT(*) AS cnt FROM t1 GROUP BY b) SELECT * FROM cte WHERE cnt > 1;
SELECT * FROM t1;
SELECT * FROM t1 WHERE EXISTS (SELECT 1 FROM t1 WHERE b < 0);
INSERT INTO t1 SELECT * FROM t1;
INSERT INTO T VALUES (1, NULL) ON CONFLICT(a) DO UPDATE SET a = excluded.a, b = excluded.b;
SELECT COUNT(*) FILTER (WHERE b IS NOT NULL), SUM(rowid) FILTER (WHERE b > 0), COUNT(*) FILTER (WHERE 1=0), COUNT(*) FILTER (WHERE 1=1), COUNT(*) FILTER (WHERE NULL), AVG(b) FILTER (WHERE b > 0 AND b < 100), COUNT(*) FILTER (WHERE typeof(b) = "text") FROM T;
INSERT INTO T DEFAULT VALUES;
ROLLBACK TO sp6990;
RELEASE sp6990;
creATE VIRTUAL TABLE t0 USING fts3("x", "y", "z");
DROP TABLE t0;
CREATE TRIGGER IF NOT EXISTS trg_T_2012 AFTER UPDATE OF a ON T BEGIN SELECT RAISE(FAIL, 'no'); END;
SELECT MIN(a) FROM T;
UPDATE t1 SET c = 'x';
SELECT AVG(a) FROM t1;

SELECT COUNT(*) FROM T;
DROP TRIGGER IF EXISTS t1;

PRAGMA temp_store = 'FILE';
INSERT OR IGNORE INTO t1 VALUES (-9, 0, -8, 9);
SELECT COUNT(*) FILTER (WHERE b IS NOT NULL), SUM(rowid) FILTER (WHERE b > 0), COUNT(*) FILTER (WHERE 1=0), COUNT(*) FILTER (WHERE 1=1), COUNT(*) FILTER (WHERE NULL), AVG(b) FILTER (WHERE b > 0 AND b < 100), COUNT(*) FILTER (WHERE typeof(b) = "text") FROM T;
ALTER TABLE t1 RENAME TO t1_r305;
INSERT INTO t1 VALUES (NULL, NULL, NULL, NULL);
SELECT MIN(a) FROM t1;
DELETE FROM T WHERE 1;
SELECT TOTAL(a) OVER (PARTITION BY a ORDER BY a ROWS BETWEEN 2 PRECEDING AND 2 FOLLOWING EXCLUDE CURRENT ROW) FROM T;
COMMIT;
```

## Actual output

```sql
0
changes: 0   total_changes: 0
changes: 0   total_changes: 0
changes: 0   total_changes: 0
changes: 0   total_changes: 0
changes: 1   total_changes: 1
changes: 1   total_changes: 2
changes: 1   total_changes: 3
changes: 1   total_changes: 3
changes: 1   total_changes: 3
CREATE TABLE "t2"("b","c","_ROWID_",PRIMARY KEY("b","c","_ROWID_"))WITHOUT ROWID;
WARNING: writing to an imposter table will corrupt the "t1bc" index!
Braun|30|3
Wernher|10|1
von|20|2
changes: 1   total_changes: 3
Braun|30
Wernher|10
von|20
changes: 1   total_changes: 3
```

## Expectation

```sql

```

## Flag

```

```

