Hi Tom
> So even with a fix that prevents examine_variable from failing, it
> seems likely that we are not managing to reduce index expressions the
> same as we will reduce query expressions later.
I think they are ok. The NullTest reduction in c925ad30b only needs the
RTE and array, not the RelOptInfo. And query quals are also folded before
any
RelOptInfo exists.
I think your patch already covered all the cases, so no need to do extra
work.
Thanks,
Shihao