Speeding up adding fky on a very large table

From: Ravi Krishna <s_ravikrishna(at)aol(dot)com>
To: "pgsql-general(at)lists(dot)postgresql(dot)org" <pgsql-general(at)lists(dot)postgresql(dot)org>
Subject: Speeding up adding fky on a very large table
Date: 2022-10-19 13:31:49
Message-ID: 1365946824.316128.1666186309386@mail.yahoo.com
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-general

AWS Aurora based on PG 13.

Large partitioned table of 5+ billion rows and 7TB in size.
ALTER TABLE abc ADD CONSTRAINT fk_123 FOREIGN KEY (a,b,c) REFERENCES xyz(1,2,3);
It seems this is not parallelized. Is there a way. Or directly going into each partition is the only way ( not even sure it is possible).

Responses

Browse pgsql-general by date

  From Date Subject
Next Message Dominique Devienne 2022-10-19 13:32:50 Re: How to store "blobs" efficiently for small and large sizes, with random access
Previous Message Dominique Devienne 2022-10-19 13:16:39 Re: How to store "blobs" efficiently for small and large sizes, with random access