Re: Which partition scheme makes sense for my time based IoT-datagrams?

From: Laurenz Albe <laurenz(dot)albe(at)cybertec(dot)at>
To: Thorsten Schöning <tschoening(at)am-soft(dot)de>, pgsql-general(at)lists(dot)postgresql(dot)org
Subject: Re: Which partition scheme makes sense for my time based IoT-datagrams?
Date: 2021-02-11 07:57:18
Message-ID: 787931207069ec7e04c42b47355511a94f0ce4dc.camel@cybertec.at
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-general

On Wed, 2021-02-10 at 18:59 +0100, Thorsten Schöning wrote:
> > They will scan all partitions. You have to be prepared that most queries
> > will become at least slightly slower with partitioning. That is
> > expected.
>
> Does "most queries" address thos efor IDs scanning all partitions or
> those time-based as well? In the end, I'm trying to improve query
> performance by reducing the size of indexes, number of rows etc. per
> table using partitions. :-)

The size of the index will barely affect its performance.

But having to figure out which partitions to scan takes planning time.

Very few queries become notably faster through partitioning.
Mostly those are aggregates and joins that match the partitioning scheme,
and sequential scans that include the partitioning key.

Yours,
Laurenz Albe
--
Cybertec | https://www.cybertec-postgresql.com

In response to

Browse pgsql-general by date

  From Date Subject
Next Message ArunKumar.SampathKumar 2021-02-11 08:57:35 Assistance on PostgreSQL DB
Previous Message Laurenz Albe 2021-02-11 07:53:31 Re: Unable to execute Query in parallel for partitioned table