Summary
We believe the query is already reduced. The issue for this bug is most likely the "BETWEEN" keyword
Minimized query
CREATE TABLE t0(c0);
INSERT INTO t0(c0) VALUES (NULL);
CREATE INDEX i0 ON t0(1) WHERE c0 NOT NULL;
SELECT 1 FROM t0 WHERE (t0.c0 IS FALSE) IS FALSE;
SELECT 1 FROM t0 WHERE (t0.c0 IS FALSE) BETWEEN FALSE AND TRUE;
Actual output
1
Expectation
1
1
Flag