Re: COLLATE: Hash partition vs UPDATE

From: Jesper Pedersen <jesper(dot)pedersen(at)redhat(dot)com>
To: Amit Langote <Langote_Amit_f8(at)lab(dot)ntt(dot)co(dot)jp>, sulamul(at)gmail(dot)com
Cc: PostgreSQL Developers <pgsql-hackers(at)lists(dot)postgresql(dot)org>, Peter Eisentraut <peter(dot)eisentraut(at)2ndquadrant(dot)com>
Subject: Re: COLLATE: Hash partition vs UPDATE
Date: 2019-04-09 12:43:57
Message-ID: 826e4d52-234a-4d35-73b2-7c6b0a92220e@redhat.com
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-hackers

Hi Amit,

On 4/8/19 11:18 PM, Amit Langote wrote:
> As of this commit, hashing functions hashtext() and hashtextextended()
> require a valid collation to be passed in. ISTM,
> satisfies_hash_partition() that's called by hash partition constraint
> checking should have been changed to use FunctionCall2Coll() interface to
> account for the requirements of the above commit. I see that it did that
> for compute_partition_hash_value(), which is used by hash partition tuple
> routing. That also seems to be covered by regression tests, but there are
> no tests that cover satisfies_hash_partition().
>
> Attached patch is an attempt to fix this. I've also added Amul Sul who
> can maybe comment on the satisfies_hash_partition() changes.
>

Yeah, that works here - apart from an issue with the test case; fixed in
the attached.

Best regards,
Jesper

Attachment Content-Type Size
satisfies_hash_partition-collate-2.patch text/x-patch 4.4 KB

In response to

Responses

Browse pgsql-hackers by date

  From Date Subject
Next Message Konstantin Knizhnik 2019-04-09 12:52:13 Re: [HACKERS] Cached plans and statement generalization
Previous Message Andres Freund 2019-04-09 12:32:20 Re: Status of the table access method work