Heikki Linnakangas <heikki(at)enterprisedb(dot)com> writes:
> Tom Lane wrote:
>> Comments, better ideas?
> How about building a separate Var-node for the variable when it's above
> an outer join?
[ itch... ] That would be a whole lot *more* invasive than what I'm
proposing now. It might be an interesting avenue to pursue,
particularly in conjunction with the planner's inability to deal with
non-nullable expressions in subselect outputs below outer joins (which
seems to require some special kind of Var to fix). But I can't see
back-patching it.
regards, tom lane