Re: parse partition strategy string in gram.y

Alvaro Herrera <alvherre@alvh.no-ip.org>

From: Alvaro Herrera <alvherre@alvh.no-ip.org>
To: "Finnerty, Jim" <jfinnert@amazon.com>
Cc: Japin Li <japinli@hotmail.com>, Justin Pryzby <pryzby@telsasoft.com>, "pgsql-hackers@lists.postgresql.org" <pgsql-hackers@lists.postgresql.org>
Date: 2022-10-24T16:13:17Z
Lists: pgsql-hackers
On 2022-Oct-24, Finnerty, Jim wrote:

> Is there a reason why HASH partitioning does not currently support
> range partition bounds, where the values in the partition bounds would
> refer to the hashed value?

Just lack of an implementation, I suppose.

> The advantage of hash partition bounds is that they are not
> domain-specific, as they are for ordinary RANGE partitions, but they
> are more flexible than MODULUS/REMAINDER partition bounds.

Well, modulus/remainder is what we have.  If you have ideas for a
different implementation, let's hear them.  I suppose we would have to
know about both the user interface and how it would internally, from two
perspectives: how does tuple routing work (ie. how to match a tuple's
values to a set of bound values), and how does partition pruning work
(ie. how do partition bounds match a query's restriction clauses).

-- 
Álvaro Herrera               48°01'N 7°57'E  —  https://www.EnterpriseDB.com/



Commits

  1. meson: Split 'main' suite into 'regress' and 'isolation'

  2. Resolve partition strategy during early parsing