Your test case is kind of silly because: * It involves an index on a constant * It uses a GROUP BY clause on a (non-integer) constant. However, the same underlying failure can be provoked without such silliness: > ~~~ CREATE TABLE t1(a INT, b INT); INSERT INTO t1(a,b) VALUES(1,null),(null,null),(1,null); CREATE UNIQUE INDEX t1b ON t1(abs(b)); SELECT * FROM t1 GROUP BY a, abs(b); ~~~ I'm testing the fix now.