Re: postgres 11.0 partition table works unexpected in update

From: Amit Langote <amitlangote09(at)gmail(dot)com>
To: zhangsilly(at)gmail(dot)com
Cc: PostgreSQL mailing lists <pgsql-bugs(at)postgresql(dot)org>
Subject: Re: postgres 11.0 partition table works unexpected in update
Date: 2018-10-24 14:26:33
Message-ID: CA+HiwqE6nWnU=EKPjpXcf4vAhLHz7gG_geHJ3fiSC7xf5wM+Jw@mail.gmail.com
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-bugs

On Wed, Oct 24, 2018 at 11:23 PM Amit Langote <amitlangote09(at)gmail(dot)com> wrote:
> On Wed, Oct 24, 2018 at 8:09 PM 张心灵 <zhangsilly(at)gmail(dot)com> wrote:
> > BTW: SELECT 14211 % 128 was 3, why record of HASH column user_id 14211 data in partition of 114?
>
> Hash partitioning doesn't apply modulus 3 directly to the value
> '14211'. It first computes its hash using the hashing function for
> bigint type and then applies the modulus.

Oops, I meant to say "doesn't apply modulus 128 directly to the value 14211".

Thanks,
Amit

In response to

Browse pgsql-bugs by date

  From Date Subject
Next Message PG Bug reporting form 2018-10-24 18:44:28 BUG #15457: please de-activate my account
Previous Message Amit Langote 2018-10-24 14:23:26 Re: postgres 11.0 partition table works unexpected in update