• Tom Lane's avatar
    Fix a couple of planner bugs introduced by the new ability to discard · 48d9d8e1
    Tom Lane authored
    ORDER BY <constant> as redundant.  One is that this means query_planner()
    has to canonicalize pathkeys even when the query jointree is empty;
    the canonicalization was always a no-op in such cases before, but no more.
    Also, we have to guard against thinking that a set-returning function is
    "constant" for this purpose.  Add a couple of regression tests for these
    evidently under-tested cases.  Per report from Greg Stark and subsequent
    experimentation.
    48d9d8e1
select.sql 5.24 KB