>>>>> "lucas" == lucas <lucas(at)lucas-nussbaum(dot)net> writes:
lucas> I would expect postgresql to figure out that "not in ('1', '2',
lucas> '3', '4')" is equivalent to "d = '0'" given that the column is
lucas> NOT NULL. And use the index.
Well, whatever you expect, nobody has ever written code for the planner
to make it figure that out (and it doesn't seem likely to be a major
win, so probably not surprising that nobody did it).
So this is not a bug.
--
Andrew (irc:RhodiumToad)