Re: Automating Partitions in PostgreSQL - Query on syntax - Mailing list pgsql-hackers

From Tom Lane
Subject Re: Automating Partitions in PostgreSQL - Query on syntax
Date
Msg-id 9546.1240339896@sss.pgh.pa.us
Whole thread Raw
In response to Re: Automating Partitions in PostgreSQL - Query on syntax  (Robert Haas <robertmhaas@gmail.com>)
Responses Re: Automating Partitions in PostgreSQL - Query on syntax  (Zeugswetter Andreas OSB sIT <Andreas.Zeugswetter@s-itsolutions.at>)
Re: Automating Partitions in PostgreSQL - Query on syntax  (Simon Riggs <simon@2ndQuadrant.com>)
List pgsql-hackers
Robert Haas <robertmhaas@gmail.com> writes:
> I'm also not sure how skillful the constraint exclusion logic is at
> proving theorems when CASE statements are involved.

It's not at all, and unlikely to become so.  However, I think worrying
about that might be focusing on the wrong thing.  If this patch expects
us to still use theorem proving to handle partition exclusion, it's
going at things in the wrong way from the get-go.  The partitioning
rules should be simple enough that they can easily be applied at runtime
to determine which partition to look in.

Which leads me to the same conclusion: anything as complicated as CASE
is the wrong design.  But perhaps for slightly different reasons.
        regards, tom lane


pgsql-hackers by date:

Previous
From: "Dickson S. Guedes"
Date:
Subject: Re: Automating Partitions in PostgreSQL - Query on syntax
Next
From: Robert Haas
Date:
Subject: Re: Automating Partitions in PostgreSQL - Query on syntax