From: Голубева Яна <ishsha@yandex.ru>
To: Michael Lewis <mlewis@entrata.com>
Cc: Tom Lane <tgl@sss.pgh.pa.us>
Cc: pgsql-general@lists.postgresql.org <pgsql-general@lists.postgresql.org>
Subject: Re: Define hash partition for certain column values
Date: Tue, 12 Jan 2021 18:51:24 +0300
Message-ID: <684591610466070@mail.yandex.ru> (raw)
In-Reply-To: <CAHOFxGp=6x6mw22re3Eo7P9g4SmTc9j7_3FwP6_BsO3fa39CvA@mail.gmail.com>
References: <2278581610342154@mail.yandex.ru>
<820805.1610346968@sss.pgh.pa.us>
<987221610348608@mail.yandex.ru>
<CAHOFxGp=6x6mw22re3Eo7P9g4SmTc9j7_3FwP6_BsO3fa39CvA@mail.gmail.com>
<div>Values for the key partitioning column are generated randomly and I can't predict their distribution between ranges.</div><div>If I just create some ranges I won't have any guarantee that partitions will have similar amount of data. It is possible that I will have 2 or 3 extremely big partitions and a bit of data in others.</div><div> </div><div>Thank you,</div><div>Iana Golubeva</div><div><br /></div><div><br /></div><div>12.01.2021, 17:55, "Michael Lewis" <mlewis@entrata.com>:</div><blockquote><div dir="ltr"><div dir="ltr">On Tue, Jan 12, 2021 at 1:21 AM Голубева Яна <<a href="mailto:ishsha@yandex.ru">ishsha@yandex.ru</a>> wrote:<br /></div><div class="f13ca48719c8a60033905b23b39675agmail_quote"><blockquote class="f13ca48719c8a60033905b23b39675agmail_quote" style="border-left-color:rgb( 204 , 204 , 204 );border-left-style:solid;border-left-width:1px;margin:0px 0px 0px 0.8ex;padding-left:1ex"><div>List or range partitioning isn't suitable for my case.<br /></div><div>I am using a column of numeric(20) type as a base for partitioning. The values of the column are generated randomly. </div><div>So there will be too many partitions if I use list partitioning as is.<br /></div></blockquote><div><br /></div><div>Sorry, but why is range not suited for this? It would seem fairly trivial to create 50 or 1000 partitions to break up the range of values allowed by your field definition.</div></div></div>
</blockquote>
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Reply to all the recipients from your mail client; the link fills in
the headers below: reply via email
Some clients, webmail especially, drop In-Reply-To and References from
a link, and the reply then starts a new thread: use the mbox below.
To: pgsql-general@postgresql.org
Cc: ishsha@yandex.ru, mlewis@entrata.com, tgl@sss.pgh.pa.us
Subject: Re: Define hash partition for certain column values
In-Reply-To: <684591610466070@mail.yandex.ru>
References: <2278581610342154@mail.yandex.ru> <820805.1610346968@sss.pgh.pa.us> <987221610348608@mail.yandex.ru> <CAHOFxGp=6x6mw22re3Eo7P9g4SmTc9j7_3FwP6_BsO3fa39CvA@mail.gmail.com> <684591610466070@mail.yandex.ru>
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
This inbox is served by DDX for PostgreSQL; see mirroring instructions
for how to clone and mirror all data and code used for this inbox