• H
    If a relation contains self-contradictory quals, don't plan it. · 75295f21
    Heikki Linnakangas 提交于
    With PostgreSQL, if you do "SELECT * FROM foo WHERE id = 1 and id = 2",
    you get a Scan node on foo, with a gating Result node with False one-time
    filter. That's what you also got on GPDB before this patch. Before merging
    the equivalence classes patch, however, you got a Result node with
    False one-time filter, with no subplan. This patch changes the behaviour
    back to that.
    
    Avoiding the planning saves some time during planning, as we don't need
    to decide how to scan the relation. But more importantly, a stand-alone
    Result node with no subplan can be executed on any segment, so the planner
    can avoid unnecessary Motion nodes in some cases.
    75295f21
plancat.c 37.9 KB