Re: "Constraint exclusion" is not general enough - Mailing list pgsql-hackers

From Tom Lane
Subject Re: "Constraint exclusion" is not general enough
Date
Msg-id 3836.1154975901@sss.pgh.pa.us
Whole thread Raw
In response to Re: "Constraint exclusion" is not general enough  (Simon Riggs <simon@2ndquadrant.com>)
List pgsql-hackers
Simon Riggs <simon@2ndquadrant.com> writes:
> To achieve the "indexed" partition pruning, we'd need
> - a way to specify that all constraints are mutually exclusive
> - a declarative approach for saying something like "arranged in date
> sequence"
> - preferably a way to have this happen at run-time so we can hard-plan a
> query with CURRENT_TIMESTAMP in the WHERE clause

Definitely a direction worth pursuing, but it seems like it would be a
completely separate code path from the existing constraint-checking
code.  I'd imagine that instead of having to prove theorems about which
tables to scan, a declarative approach would let us "just know" what
to do.
        regards, tom lane


pgsql-hackers by date:

Previous
From: Tom Lane
Date:
Subject: Re: buildfarm - make check failures for leveret on 8.0 and 8.1
Next
From: Jeremy Drake
Date:
Subject: Re: buildfarm - make check failures for leveret on 8.0