On Thu, 2023-11-30 at 19:22 +0530, Ashutosh Bapat wrote: > May be attach the patch to hackers thread (this) as well?
If you want, sure. I thought it was good enough if the thread is accessible via the commitfest app. Yours, Laurenz Albe
From ecdce740586e33eeb394d47564b10f813896ff11 Mon Sep 17 00:00:00 2001 From: Laurenz Albe <laurenz.a...@cybertec.at> Date: Mon, 9 Jan 2023 16:38:58 +0100 Subject: [PATCH] Fix omission in partitioning limitation documentation UNIQUE and PRIMARY KEY constraints can be created on ONLY the partitioned table. We already had an example demonstrating that, but forgot to mention it in the documentation of the limits of partitioning. Author: Laurenz Albe Discussion: https://postgr.es/m/167299368731.659.16130012959616771...@wrigleys.postgresql.org --- doc/src/sgml/ddl.sgml | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/doc/src/sgml/ddl.sgml b/doc/src/sgml/ddl.sgml index 6e92bbddd2..b4a75f9c8f 100644 --- a/doc/src/sgml/ddl.sgml +++ b/doc/src/sgml/ddl.sgml @@ -4282,7 +4282,10 @@ ALTER INDEX measurement_city_id_logdate_key Using <literal>ONLY</literal> to add or drop a constraint on only the partitioned table is supported as long as there are no partitions. Once partitions exist, using <literal>ONLY</literal> - will result in an error. Instead, constraints on the partitions + will result in an error (the exception to this are + <literal>UNIQUE</literal> and <literal>PRIMARY KEY</literal> + constraints, which will be created with an invalid index, as shown in + the example above). Instead, constraints on the partitions themselves can be added and (if they are not present in the parent table) dropped. </para> -- 2.39.0