Re: Performance implications of partitioning by UUIDv7 range in PostgreSQL v18 - Mailing list pgsql-performance

From Laurenz Albe
Subject Re: Performance implications of partitioning by UUIDv7 range in PostgreSQL v18
Date
Msg-id b0991c2d8348da5b97bb0cdb1fe7a3d6a21a0df6.camel@cybertec.at
Whole thread Raw
In response to Re: Performance implications of partitioning by UUIDv7 range in PostgreSQL v18  (David Rowley <dgrowleyml@gmail.com>)
Responses Re: Performance implications of partitioning by UUIDv7 range in PostgreSQL v18
List pgsql-performance
On Fri, 2025-10-24 at 11:54 +1300, David Rowley wrote:
> On Fri, 24 Oct 2025 at 09:38, Laurenz Albe <laurenz.albe@cybertec.at> wrote:
> > I recommend that you create a primary key on each partition rather than having one
> > on the partitioned table.
>
> It might be worth mentioning that doing that would forego having the
> ability to reference the partitioned table in a foreign key
> constraint.

Right, but referencing a partitioned table with a foreign key is a mixed blessing
anyway: you could no longer drop partitions from the partitioned table without
scanning the referencing table to verify that the foreign key is not violated.

Yours,
Laurenz Albe



pgsql-performance by date:

Previous
From: Jonathan Reis
Date:
Subject: Re: Performance implications of partitioning by UUIDv7 range in PostgreSQL v18
Next
From: Greg Sabino Mullane
Date:
Subject: Re: Performance implications of partitioning by UUIDv7 range in PostgreSQL v18