## 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
.timer on
CREATE TEMPORARY TABLE t0(x, y, z);
SELECT -99999999999999999999999999999999999999999999999999;
SELECT * FROM sqlite_temp_master WHERE sql GLOB '000[]***';
DROP TABLE t0;
ATTACH DATABASE ':memory:' AS aux41;
ATTACH DATABASE ':memory:' AS aux57;
CREATE TABLE T (
  a INTEGER,
  b REAL
);
INSERT INTO T VALUES (pi(),-9223372036854775808), (2,-2.5), (3,0.0);
CREATE INDEX c
ON T(b);
SELECT * FROM T WHERE b >= -2.5 AND b < 2.0;

SELECT COUNT(*) FROM T;
REINDEX;
SELECT SUM(b) FROM T;
SELECT COUNT(*) FROM T;
DELETE FROM T WHERE 0;
DELETE FROM T WHERE b > (SELECT AVG(b) FROM T);
CREATE TRIGGER IF NOT EXISTS trg_T_842 BEFORE DELETE ON T BEGIN SELECT RAISE(IGNORE); END;
CREATE  INDEX IF NOT EXISTS idx_T_1447 ON T(lower(b));
DETACH DATABASE aux57;
SELECT AVG(a) FILTER (WHERE a != 0) OVER (PARTITION BY a ORDER BY a ROWS BETWEEN 2 PRECEDING AND 2 FOLLOWING EXCLUDE CURRENT ROW) FROM T;
DELETE FROM T WHERE b IS NULL;
WITH a AS (SELECT * FROM T), b AS (SELECT * FROM a) SELECT * FROM b;
DETACH DATABASE aux41;

SELECT COUNT(*) FROM T;
PRAGMA defer_foreign_keys = NO;
```

## Actual output

```sql
Run Time: real 0.001 user 0.000337 sys 0.000000
-1.0e+50
Run Time: real 0.000 user 0.000020 sys 0.000000
Run Time: real 0.000 user 0.000032 sys 0.000000
Run Time: real 0.000 user 0.000110 sys 0.000000
Run Time: real 0.000 user 0.000045 sys 0.000000
Run Time: real 0.000 user 0.000031 sys 0.000000
Run Time: real 0.000 user 0.000077 sys 0.000000
Run Time: real 0.000 user 0.000032 sys 0.000000
Run Time: real 0.000 user 0.000082 sys 0.000000
2|-2.5
3|0.0
Run Time: real 0.000 user 0.000040 sys 0.000000
3
Run Time: real 0.000 user 0.000014 sys 0.000000
Run Time: real 0.000 user 0.000015 sys 0.000000
-9.22337203685478e+18
Run Time: real 0.000 user 0.000020 sys 0.000000
3
Run Time: real 0.000 user 0.000007 sys 0.000000
Run Time: real 0.000 user 0.000015 sys 0.000000
Run Time: real 0.000 user 0.000051 sys 0.000000
Run Time: real 0.001 user 0.000074 sys 0.000000
Run Time: real 0.000 user 0.000078 sys 0.000000
Run Time: real 0.000 user 0.000011 sys 0.000000

Run Time: real 0.000 user 0.000104 sys 0.000000
Run Time: real 0.000 user 0.000036 sys 0.000000
3.14159265358979|-9.22337203685478e+18
Run Time: real 0.000 user 0.000036 sys 0.000000
Run Time: real 0.000 user 0.000007 sys 0.000000
1
Run Time: real 0.000 user 0.000011 sys 0.000000
Run Time: real 0.000 user 0.000011 sys 0.000000
```

## Expectation

```sql
Run Time: real 0.000151 user 0.000160 sys 0.000000
-1.0e+50
Run Time: real 0.000010 user 0.000010 sys 0.000000
Run Time: real 0.000015 user 0.000015 sys 0.000000
Run Time: real 0.000062 user 0.000062 sys 0.000000
Run Time: real 0.000018 user 0.000018 sys 0.000000
Run Time: real 0.000013 user 0.000013 sys 0.000000
Run Time: real 0.000030 user 0.000030 sys 0.000000
Run Time: real 0.000018 user 0.000018 sys 0.000000
Run Time: real 0.000035 user 0.000035 sys 0.000000
2|-2.5
3|0.0
Run Time: real 0.000015 user 0.000016 sys 0.000000
3
Run Time: real 0.000006 user 0.000007 sys 0.000000
Run Time: real 0.000005 user 0.000005 sys 0.000000
-9.22337203685478e+18
Run Time: real 0.000009 user 0.000009 sys 0.000000
3
Run Time: real 0.000003 user 0.000003 sys 0.000000
Run Time: real 0.000005 user 0.000005 sys 0.000000
Run Time: real 0.000022 user 0.000022 sys 0.000000
Run Time: real 0.000024 user 0.000024 sys 0.000000
Run Time: real 0.000025 user 0.000026 sys 0.000000
Run Time: real 0.000004 user 0.000004 sys 0.000000

Run Time: real 0.000050 user 0.000049 sys 0.000000
Run Time: real 0.000013 user 0.000014 sys 0.000000
3.14159265358979|-9.22337203685478e+18
Run Time: real 0.000015 user 0.000015 sys 0.000000
Run Time: real 0.000002 user 0.000002 sys 0.000000
1
Run Time: real 0.000004 user 0.000004 sys 0.000000
Run Time: real 0.000003 user 0.000003 sys 0.000000
```

## Flag

```

```

