Re: bugs or my fault

Поиск
Список
Период
Сортировка
От Sergei Kornilov
Тема Re: bugs or my fault
Дата
Msg-id 176211631710564@mail.yandex.ru
обсуждение исходный текст
Ответ на Re: bugs or my fault  (Yudianto Prasetyo <mr.yudianto@gmail.com>)
Ответы Re: bugs or my fault  (Yudianto Prasetyo <mr.yudianto@gmail.com>)
Список pgsql-bugs
We don't do just id % 3, we calculate some hash value from partition key (id) and route the tuple according this hash
value.Such condition for your example:
 

select *, satisfies_hash_partition('myschema.customers'::regclass, 3, 0, id) as modulus3_remainder0_target_partition
frommyschema.cust0;
 

Can't illustrate more at the SQL level due to the lack of a uint64 calculations. At C level we are here:
https://github.com/postgres/postgres/blob/REL_13_STABLE/src/backend/partitioning/partbounds.c#L4595

regards, Sergei



В списке pgsql-bugs по дате отправления:

Предыдущее
От: Yudianto Prasetyo
Дата:
Сообщение: Re: bugs or my fault
Следующее
От: Yudianto Prasetyo
Дата:
Сообщение: Re: bugs or my fault