agora inbox for [email protected]help / color / mirror / Atom feed
[PATCH 4/4] Add a note about DROP NOT NULL and partitions 53+ messages / 2 participants [nested] [flat]
* [PATCH 2/3] Add a note about DROP NOT NULL and partitions @ 2017-02-10 06:03 amit <[email protected]> 0 siblings, 0 replies; 53+ messages in thread From: amit @ 2017-02-10 06:03 UTC (permalink / raw) On the ALTER TABLE refpage, it seems better to mention how to drop drop the not null constraint of a partition's column. Per suggestion from Corey Huinker. --- doc/src/sgml/ref/alter_table.sgml | 9 +++++++-- 1 file changed, 7 insertions(+), 2 deletions(-) diff --git a/doc/src/sgml/ref/alter_table.sgml b/doc/src/sgml/ref/alter_table.sgml index 077c00373d..b6be3a0dcb 100644 --- a/doc/src/sgml/ref/alter_table.sgml +++ b/doc/src/sgml/ref/alter_table.sgml @@ -172,9 +172,14 @@ ALTER TABLE [ IF EXISTS ] <replaceable class="PARAMETER">name</replaceable> </para> <para> - If this table is a partition, one cannot perform <literal>DROP NOT NULL</> + If this table is a partition, one cannot perform <literal>DROP NOT NULL</literal> on a column if it is marked <literal>NOT NULL</literal> in the parent - table. + table. To drop the <literal>NOT NULL</literal> constraint from all the + partitions, perform <literal>DROP NOT NULL</literal> on the parent + table. Even if there is no <literal>NOT NULL</> constraint on the + parent, such a constraint can still be added to individual partitions, + if desired; that is, the children can disallow nulls even if the parent + allows them, but not the other way around. </para> </listitem> </varlistentry> -- 2.11.0 --------------19C79A137EF2D0DB3BE72F79 Content-Type: text/x-diff; name="0003-Listify-a-note-on-the-CREATE-TABLE-page.patch" Content-Transfer-Encoding: 7bit Content-Disposition: attachment; filename="0003-Listify-a-note-on-the-CREATE-TABLE-page.patch" ^ permalink raw reply [nested|flat] 53+ messages in thread
* [PATCH 2/3] Add a note about DROP NOT NULL and partitions @ 2017-02-10 06:03 amit <[email protected]> 0 siblings, 0 replies; 53+ messages in thread From: amit @ 2017-02-10 06:03 UTC (permalink / raw) On the ALTER TABLE refpage, it seems better to mention how to drop drop the not null constraint of a partition's column. Per suggestion from Corey Huinker. --- doc/src/sgml/ref/alter_table.sgml | 9 +++++++-- 1 file changed, 7 insertions(+), 2 deletions(-) diff --git a/doc/src/sgml/ref/alter_table.sgml b/doc/src/sgml/ref/alter_table.sgml index 077c00373d..b6be3a0dcb 100644 --- a/doc/src/sgml/ref/alter_table.sgml +++ b/doc/src/sgml/ref/alter_table.sgml @@ -172,9 +172,14 @@ ALTER TABLE [ IF EXISTS ] <replaceable class="PARAMETER">name</replaceable> </para> <para> - If this table is a partition, one cannot perform <literal>DROP NOT NULL</> + If this table is a partition, one cannot perform <literal>DROP NOT NULL</literal> on a column if it is marked <literal>NOT NULL</literal> in the parent - table. + table. To drop the <literal>NOT NULL</literal> constraint from all the + partitions, perform <literal>DROP NOT NULL</literal> on the parent + table. Even if there is no <literal>NOT NULL</> constraint on the + parent, such a constraint can still be added to individual partitions, + if desired; that is, the children can disallow nulls even if the parent + allows them, but not the other way around. </para> </listitem> </varlistentry> -- 2.11.0 --------------19C79A137EF2D0DB3BE72F79 Content-Type: text/x-diff; name="0003-Listify-a-note-on-the-CREATE-TABLE-page.patch" Content-Transfer-Encoding: 7bit Content-Disposition: attachment; filename="0003-Listify-a-note-on-the-CREATE-TABLE-page.patch" ^ permalink raw reply [nested|flat] 53+ messages in thread
* [PATCH 2/3] Add a note about DROP NOT NULL and partitions @ 2017-02-10 06:03 amit <[email protected]> 0 siblings, 0 replies; 53+ messages in thread From: amit @ 2017-02-10 06:03 UTC (permalink / raw) On the ALTER TABLE refpage, it seems better to mention how to drop drop the not null constraint of a partition's column. Per suggestion from Corey Huinker. --- doc/src/sgml/ref/alter_table.sgml | 9 +++++++-- 1 file changed, 7 insertions(+), 2 deletions(-) diff --git a/doc/src/sgml/ref/alter_table.sgml b/doc/src/sgml/ref/alter_table.sgml index 077c00373d..b6be3a0dcb 100644 --- a/doc/src/sgml/ref/alter_table.sgml +++ b/doc/src/sgml/ref/alter_table.sgml @@ -172,9 +172,14 @@ ALTER TABLE [ IF EXISTS ] <replaceable class="PARAMETER">name</replaceable> </para> <para> - If this table is a partition, one cannot perform <literal>DROP NOT NULL</> + If this table is a partition, one cannot perform <literal>DROP NOT NULL</literal> on a column if it is marked <literal>NOT NULL</literal> in the parent - table. + table. To drop the <literal>NOT NULL</literal> constraint from all the + partitions, perform <literal>DROP NOT NULL</literal> on the parent + table. Even if there is no <literal>NOT NULL</> constraint on the + parent, such a constraint can still be added to individual partitions, + if desired; that is, the children can disallow nulls even if the parent + allows them, but not the other way around. </para> </listitem> </varlistentry> -- 2.11.0 --------------19C79A137EF2D0DB3BE72F79 Content-Type: text/x-diff; name="0003-Listify-a-note-on-the-CREATE-TABLE-page.patch" Content-Transfer-Encoding: 7bit Content-Disposition: attachment; filename="0003-Listify-a-note-on-the-CREATE-TABLE-page.patch" ^ permalink raw reply [nested|flat] 53+ messages in thread
* [PATCH 2/3] Add a note about DROP NOT NULL and partitions @ 2017-02-10 06:03 amit <[email protected]> 0 siblings, 0 replies; 53+ messages in thread From: amit @ 2017-02-10 06:03 UTC (permalink / raw) On the ALTER TABLE refpage, it seems better to mention how to drop drop the not null constraint of a partition's column. Per suggestion from Corey Huinker. --- doc/src/sgml/ref/alter_table.sgml | 8 ++++++-- 1 file changed, 6 insertions(+), 2 deletions(-) diff --git a/doc/src/sgml/ref/alter_table.sgml b/doc/src/sgml/ref/alter_table.sgml index da431f8369..be857882bb 100644 --- a/doc/src/sgml/ref/alter_table.sgml +++ b/doc/src/sgml/ref/alter_table.sgml @@ -172,9 +172,13 @@ ALTER TABLE [ IF EXISTS ] <replaceable class="PARAMETER">name</replaceable> </para> <para> - If this table is a partition, one cannot perform <literal>DROP NOT NULL</> + If this table is a partition, one cannot perform <literal>DROP NOT NULL</literal> on a column if it is marked <literal>NOT NULL</literal> in the parent - table. + table. To drop the <literal>NOT NULL</literal> constraint from all the + partitions, perform <literal>DROP NOT NULL</literal> on the parent + table. One might however want to set it for only some partitions, + which is possible by doing <literal>SET NOT NULL</literal> on individual + partitions. </para> </listitem> </varlistentry> -- 2.11.0 --------------434C61868FD2E7C005F82712 Content-Type: text/x-diff; name="0003-Listify-a-note-on-the-CREATE-TABLE-page.patch" Content-Transfer-Encoding: 7bit Content-Disposition: attachment; filename="0003-Listify-a-note-on-the-CREATE-TABLE-page.patch" ^ permalink raw reply [nested|flat] 53+ messages in thread
* [PATCH 4/4] Add a note about DROP NOT NULL and partitions @ 2017-02-10 06:03 amit <[email protected]> 0 siblings, 0 replies; 53+ messages in thread From: amit @ 2017-02-10 06:03 UTC (permalink / raw) On the ALTER TABLE refpage, it seems better to mention how to drop drop the not null constraint of a partition's column. Per suggestion from Corey Huinker. --- doc/src/sgml/ref/alter_table.sgml | 8 ++++++-- 1 file changed, 6 insertions(+), 2 deletions(-) diff --git a/doc/src/sgml/ref/alter_table.sgml b/doc/src/sgml/ref/alter_table.sgml index da431f8369..be857882bb 100644 --- a/doc/src/sgml/ref/alter_table.sgml +++ b/doc/src/sgml/ref/alter_table.sgml @@ -172,9 +172,13 @@ ALTER TABLE [ IF EXISTS ] <replaceable class="PARAMETER">name</replaceable> </para> <para> - If this table is a partition, one cannot perform <literal>DROP NOT NULL</> + If this table is a partition, one cannot perform <literal>DROP NOT NULL</literal> on a column if it is marked <literal>NOT NULL</literal> in the parent - table. + table. To drop the <literal>NOT NULL</literal> constraint from all the + partitions, perform <literal>DROP NOT NULL</literal> on the parent + table. One might however want to set it for only some partitions, + which is possible by doing <literal>SET NOT NULL</literal> on individual + partitions. </para> </listitem> </varlistentry> -- 2.11.0 --------------89FC639615756AE2477DE3D6 Content-Type: text/plain Content-Disposition: inline Content-Transfer-Encoding: 8bit MIME-Version: 1.0 -- Sent via pgsql-hackers mailing list ([email protected]) To make changes to your subscription: http://www.postgresql.org/mailpref/pgsql-hackers --------------89FC639615756AE2477DE3D6-- ^ permalink raw reply [nested|flat] 53+ messages in thread
* [PATCH 2/3] Add a note about DROP NOT NULL and partitions @ 2017-02-10 06:03 amit <[email protected]> 0 siblings, 0 replies; 53+ messages in thread From: amit @ 2017-02-10 06:03 UTC (permalink / raw) On the ALTER TABLE refpage, it seems better to mention how to drop drop the not null constraint of a partition's column. Per suggestion from Corey Huinker. --- doc/src/sgml/ref/alter_table.sgml | 8 ++++++-- 1 file changed, 6 insertions(+), 2 deletions(-) diff --git a/doc/src/sgml/ref/alter_table.sgml b/doc/src/sgml/ref/alter_table.sgml index da431f8369..be857882bb 100644 --- a/doc/src/sgml/ref/alter_table.sgml +++ b/doc/src/sgml/ref/alter_table.sgml @@ -172,9 +172,13 @@ ALTER TABLE [ IF EXISTS ] <replaceable class="PARAMETER">name</replaceable> </para> <para> - If this table is a partition, one cannot perform <literal>DROP NOT NULL</> + If this table is a partition, one cannot perform <literal>DROP NOT NULL</literal> on a column if it is marked <literal>NOT NULL</literal> in the parent - table. + table. To drop the <literal>NOT NULL</literal> constraint from all the + partitions, perform <literal>DROP NOT NULL</literal> on the parent + table. One might however want to set it for only some partitions, + which is possible by doing <literal>SET NOT NULL</literal> on individual + partitions. </para> </listitem> </varlistentry> -- 2.11.0 --------------434C61868FD2E7C005F82712 Content-Type: text/x-diff; name="0003-Listify-a-note-on-the-CREATE-TABLE-page.patch" Content-Transfer-Encoding: 7bit Content-Disposition: attachment; filename="0003-Listify-a-note-on-the-CREATE-TABLE-page.patch" ^ permalink raw reply [nested|flat] 53+ messages in thread
* [PATCH 2/3] Add a note about DROP NOT NULL and partitions @ 2017-02-10 06:03 amit <[email protected]> 0 siblings, 0 replies; 53+ messages in thread From: amit @ 2017-02-10 06:03 UTC (permalink / raw) On the ALTER TABLE refpage, it seems better to mention how to drop drop the not null constraint of a partition's column. Per suggestion from Corey Huinker. --- doc/src/sgml/ref/alter_table.sgml | 8 ++++++-- 1 file changed, 6 insertions(+), 2 deletions(-) diff --git a/doc/src/sgml/ref/alter_table.sgml b/doc/src/sgml/ref/alter_table.sgml index da431f8369..be857882bb 100644 --- a/doc/src/sgml/ref/alter_table.sgml +++ b/doc/src/sgml/ref/alter_table.sgml @@ -172,9 +172,13 @@ ALTER TABLE [ IF EXISTS ] <replaceable class="PARAMETER">name</replaceable> </para> <para> - If this table is a partition, one cannot perform <literal>DROP NOT NULL</> + If this table is a partition, one cannot perform <literal>DROP NOT NULL</literal> on a column if it is marked <literal>NOT NULL</literal> in the parent - table. + table. To drop the <literal>NOT NULL</literal> constraint from all the + partitions, perform <literal>DROP NOT NULL</literal> on the parent + table. One might however want to set it for only some partitions, + which is possible by doing <literal>SET NOT NULL</literal> on individual + partitions. </para> </listitem> </varlistentry> -- 2.11.0 --------------434C61868FD2E7C005F82712 Content-Type: text/x-diff; name="0003-Listify-a-note-on-the-CREATE-TABLE-page.patch" Content-Transfer-Encoding: 7bit Content-Disposition: attachment; filename="0003-Listify-a-note-on-the-CREATE-TABLE-page.patch" ^ permalink raw reply [nested|flat] 53+ messages in thread
* [PATCH 4/4] Add a note about DROP NOT NULL and partitions @ 2017-02-10 06:03 amit <[email protected]> 0 siblings, 0 replies; 53+ messages in thread From: amit @ 2017-02-10 06:03 UTC (permalink / raw) On the ALTER TABLE refpage, it seems better to mention how to drop drop the not null constraint of a partition's column. Per suggestion from Corey Huinker. --- doc/src/sgml/ref/alter_table.sgml | 8 ++++++-- 1 file changed, 6 insertions(+), 2 deletions(-) diff --git a/doc/src/sgml/ref/alter_table.sgml b/doc/src/sgml/ref/alter_table.sgml index da431f8369..be857882bb 100644 --- a/doc/src/sgml/ref/alter_table.sgml +++ b/doc/src/sgml/ref/alter_table.sgml @@ -172,9 +172,13 @@ ALTER TABLE [ IF EXISTS ] <replaceable class="PARAMETER">name</replaceable> </para> <para> - If this table is a partition, one cannot perform <literal>DROP NOT NULL</> + If this table is a partition, one cannot perform <literal>DROP NOT NULL</literal> on a column if it is marked <literal>NOT NULL</literal> in the parent - table. + table. To drop the <literal>NOT NULL</literal> constraint from all the + partitions, perform <literal>DROP NOT NULL</literal> on the parent + table. One might however want to set it for only some partitions, + which is possible by doing <literal>SET NOT NULL</literal> on individual + partitions. </para> </listitem> </varlistentry> -- 2.11.0 --------------89FC639615756AE2477DE3D6 Content-Type: text/plain Content-Disposition: inline Content-Transfer-Encoding: 8bit MIME-Version: 1.0 -- Sent via pgsql-hackers mailing list ([email protected]) To make changes to your subscription: http://www.postgresql.org/mailpref/pgsql-hackers --------------89FC639615756AE2477DE3D6-- ^ permalink raw reply [nested|flat] 53+ messages in thread
* [PATCH 2/3] Add a note about DROP NOT NULL and partitions @ 2017-02-10 06:03 amit <[email protected]> 0 siblings, 0 replies; 53+ messages in thread From: amit @ 2017-02-10 06:03 UTC (permalink / raw) On the ALTER TABLE refpage, it seems better to mention how to drop drop the not null constraint of a partition's column. Per suggestion from Corey Huinker. --- doc/src/sgml/ref/alter_table.sgml | 9 +++++++-- 1 file changed, 7 insertions(+), 2 deletions(-) diff --git a/doc/src/sgml/ref/alter_table.sgml b/doc/src/sgml/ref/alter_table.sgml index 077c00373d..b6be3a0dcb 100644 --- a/doc/src/sgml/ref/alter_table.sgml +++ b/doc/src/sgml/ref/alter_table.sgml @@ -172,9 +172,14 @@ ALTER TABLE [ IF EXISTS ] <replaceable class="PARAMETER">name</replaceable> </para> <para> - If this table is a partition, one cannot perform <literal>DROP NOT NULL</> + If this table is a partition, one cannot perform <literal>DROP NOT NULL</literal> on a column if it is marked <literal>NOT NULL</literal> in the parent - table. + table. To drop the <literal>NOT NULL</literal> constraint from all the + partitions, perform <literal>DROP NOT NULL</literal> on the parent + table. Even if there is no <literal>NOT NULL</> constraint on the + parent, such a constraint can still be added to individual partitions, + if desired; that is, the children can disallow nulls even if the parent + allows them, but not the other way around. </para> </listitem> </varlistentry> -- 2.11.0 --------------19C79A137EF2D0DB3BE72F79 Content-Type: text/x-diff; name="0003-Listify-a-note-on-the-CREATE-TABLE-page.patch" Content-Transfer-Encoding: 7bit Content-Disposition: attachment; filename="0003-Listify-a-note-on-the-CREATE-TABLE-page.patch" ^ permalink raw reply [nested|flat] 53+ messages in thread
* [PATCH 2/3] Add a note about DROP NOT NULL and partitions @ 2017-02-10 06:03 amit <[email protected]> 0 siblings, 0 replies; 53+ messages in thread From: amit @ 2017-02-10 06:03 UTC (permalink / raw) On the ALTER TABLE refpage, it seems better to mention how to drop drop the not null constraint of a partition's column. Per suggestion from Corey Huinker. --- doc/src/sgml/ref/alter_table.sgml | 9 +++++++-- 1 file changed, 7 insertions(+), 2 deletions(-) diff --git a/doc/src/sgml/ref/alter_table.sgml b/doc/src/sgml/ref/alter_table.sgml index 077c00373d..b6be3a0dcb 100644 --- a/doc/src/sgml/ref/alter_table.sgml +++ b/doc/src/sgml/ref/alter_table.sgml @@ -172,9 +172,14 @@ ALTER TABLE [ IF EXISTS ] <replaceable class="PARAMETER">name</replaceable> </para> <para> - If this table is a partition, one cannot perform <literal>DROP NOT NULL</> + If this table is a partition, one cannot perform <literal>DROP NOT NULL</literal> on a column if it is marked <literal>NOT NULL</literal> in the parent - table. + table. To drop the <literal>NOT NULL</literal> constraint from all the + partitions, perform <literal>DROP NOT NULL</literal> on the parent + table. Even if there is no <literal>NOT NULL</> constraint on the + parent, such a constraint can still be added to individual partitions, + if desired; that is, the children can disallow nulls even if the parent + allows them, but not the other way around. </para> </listitem> </varlistentry> -- 2.11.0 --------------19C79A137EF2D0DB3BE72F79 Content-Type: text/x-diff; name="0003-Listify-a-note-on-the-CREATE-TABLE-page.patch" Content-Transfer-Encoding: 7bit Content-Disposition: attachment; filename="0003-Listify-a-note-on-the-CREATE-TABLE-page.patch" ^ permalink raw reply [nested|flat] 53+ messages in thread
* [PATCH 4/4] Add a note about DROP NOT NULL and partitions @ 2017-02-10 06:03 amit <[email protected]> 0 siblings, 0 replies; 53+ messages in thread From: amit @ 2017-02-10 06:03 UTC (permalink / raw) On the ALTER TABLE refpage, it seems better to mention how to drop drop the not null constraint of a partition's column. Per suggestion from Corey Huinker. --- doc/src/sgml/ref/alter_table.sgml | 8 ++++++-- 1 file changed, 6 insertions(+), 2 deletions(-) diff --git a/doc/src/sgml/ref/alter_table.sgml b/doc/src/sgml/ref/alter_table.sgml index da431f8369..be857882bb 100644 --- a/doc/src/sgml/ref/alter_table.sgml +++ b/doc/src/sgml/ref/alter_table.sgml @@ -172,9 +172,13 @@ ALTER TABLE [ IF EXISTS ] <replaceable class="PARAMETER">name</replaceable> </para> <para> - If this table is a partition, one cannot perform <literal>DROP NOT NULL</> + If this table is a partition, one cannot perform <literal>DROP NOT NULL</literal> on a column if it is marked <literal>NOT NULL</literal> in the parent - table. + table. To drop the <literal>NOT NULL</literal> constraint from all the + partitions, perform <literal>DROP NOT NULL</literal> on the parent + table. One might however want to set it for only some partitions, + which is possible by doing <literal>SET NOT NULL</literal> on individual + partitions. </para> </listitem> </varlistentry> -- 2.11.0 --------------89FC639615756AE2477DE3D6 Content-Type: text/plain Content-Disposition: inline Content-Transfer-Encoding: 8bit MIME-Version: 1.0 -- Sent via pgsql-hackers mailing list ([email protected]) To make changes to your subscription: http://www.postgresql.org/mailpref/pgsql-hackers --------------89FC639615756AE2477DE3D6-- ^ permalink raw reply [nested|flat] 53+ messages in thread
* [PATCH 4/4] Add a note about DROP NOT NULL and partitions @ 2017-02-10 06:03 amit <[email protected]> 0 siblings, 0 replies; 53+ messages in thread From: amit @ 2017-02-10 06:03 UTC (permalink / raw) On the ALTER TABLE refpage, it seems better to mention how to drop drop the not null constraint of a partition's column. Per suggestion from Corey Huinker. --- doc/src/sgml/ref/alter_table.sgml | 8 ++++++-- 1 file changed, 6 insertions(+), 2 deletions(-) diff --git a/doc/src/sgml/ref/alter_table.sgml b/doc/src/sgml/ref/alter_table.sgml index da431f8369..be857882bb 100644 --- a/doc/src/sgml/ref/alter_table.sgml +++ b/doc/src/sgml/ref/alter_table.sgml @@ -172,9 +172,13 @@ ALTER TABLE [ IF EXISTS ] <replaceable class="PARAMETER">name</replaceable> </para> <para> - If this table is a partition, one cannot perform <literal>DROP NOT NULL</> + If this table is a partition, one cannot perform <literal>DROP NOT NULL</literal> on a column if it is marked <literal>NOT NULL</literal> in the parent - table. + table. To drop the <literal>NOT NULL</literal> constraint from all the + partitions, perform <literal>DROP NOT NULL</literal> on the parent + table. One might however want to set it for only some partitions, + which is possible by doing <literal>SET NOT NULL</literal> on individual + partitions. </para> </listitem> </varlistentry> -- 2.11.0 --------------89FC639615756AE2477DE3D6 Content-Type: text/plain Content-Disposition: inline Content-Transfer-Encoding: 8bit MIME-Version: 1.0 -- Sent via pgsql-hackers mailing list ([email protected]) To make changes to your subscription: http://www.postgresql.org/mailpref/pgsql-hackers --------------89FC639615756AE2477DE3D6-- ^ permalink raw reply [nested|flat] 53+ messages in thread
* [PATCH 4/4] Add a note about DROP NOT NULL and partitions @ 2017-02-10 06:03 amit <[email protected]> 0 siblings, 0 replies; 53+ messages in thread From: amit @ 2017-02-10 06:03 UTC (permalink / raw) On the ALTER TABLE refpage, it seems better to mention how to drop drop the not null constraint of a partition's column. Per suggestion from Corey Huinker. --- doc/src/sgml/ref/alter_table.sgml | 8 ++++++-- 1 file changed, 6 insertions(+), 2 deletions(-) diff --git a/doc/src/sgml/ref/alter_table.sgml b/doc/src/sgml/ref/alter_table.sgml index da431f8369..be857882bb 100644 --- a/doc/src/sgml/ref/alter_table.sgml +++ b/doc/src/sgml/ref/alter_table.sgml @@ -172,9 +172,13 @@ ALTER TABLE [ IF EXISTS ] <replaceable class="PARAMETER">name</replaceable> </para> <para> - If this table is a partition, one cannot perform <literal>DROP NOT NULL</> + If this table is a partition, one cannot perform <literal>DROP NOT NULL</literal> on a column if it is marked <literal>NOT NULL</literal> in the parent - table. + table. To drop the <literal>NOT NULL</literal> constraint from all the + partitions, perform <literal>DROP NOT NULL</literal> on the parent + table. One might however want to set it for only some partitions, + which is possible by doing <literal>SET NOT NULL</literal> on individual + partitions. </para> </listitem> </varlistentry> -- 2.11.0 --------------89FC639615756AE2477DE3D6 Content-Type: text/plain Content-Disposition: inline Content-Transfer-Encoding: 8bit MIME-Version: 1.0 -- Sent via pgsql-hackers mailing list ([email protected]) To make changes to your subscription: http://www.postgresql.org/mailpref/pgsql-hackers --------------89FC639615756AE2477DE3D6-- ^ permalink raw reply [nested|flat] 53+ messages in thread
* [PATCH 4/4] Add a note about DROP NOT NULL and partitions @ 2017-02-10 06:03 amit <[email protected]> 0 siblings, 0 replies; 53+ messages in thread From: amit @ 2017-02-10 06:03 UTC (permalink / raw) On the ALTER TABLE refpage, it seems better to mention how to drop drop the not null constraint of a partition's column. Per suggestion from Corey Huinker. --- doc/src/sgml/ref/alter_table.sgml | 8 ++++++-- 1 file changed, 6 insertions(+), 2 deletions(-) diff --git a/doc/src/sgml/ref/alter_table.sgml b/doc/src/sgml/ref/alter_table.sgml index da431f8369..be857882bb 100644 --- a/doc/src/sgml/ref/alter_table.sgml +++ b/doc/src/sgml/ref/alter_table.sgml @@ -172,9 +172,13 @@ ALTER TABLE [ IF EXISTS ] <replaceable class="PARAMETER">name</replaceable> </para> <para> - If this table is a partition, one cannot perform <literal>DROP NOT NULL</> + If this table is a partition, one cannot perform <literal>DROP NOT NULL</literal> on a column if it is marked <literal>NOT NULL</literal> in the parent - table. + table. To drop the <literal>NOT NULL</literal> constraint from all the + partitions, perform <literal>DROP NOT NULL</literal> on the parent + table. One might however want to set it for only some partitions, + which is possible by doing <literal>SET NOT NULL</literal> on individual + partitions. </para> </listitem> </varlistentry> -- 2.11.0 --------------89FC639615756AE2477DE3D6 Content-Type: text/plain Content-Disposition: inline Content-Transfer-Encoding: 8bit MIME-Version: 1.0 -- Sent via pgsql-hackers mailing list ([email protected]) To make changes to your subscription: http://www.postgresql.org/mailpref/pgsql-hackers --------------89FC639615756AE2477DE3D6-- ^ permalink raw reply [nested|flat] 53+ messages in thread
* [PATCH 4/4] Add a note about DROP NOT NULL and partitions @ 2017-02-10 06:03 amit <[email protected]> 0 siblings, 0 replies; 53+ messages in thread From: amit @ 2017-02-10 06:03 UTC (permalink / raw) On the ALTER TABLE refpage, it seems better to mention how to drop drop the not null constraint of a partition's column. Per suggestion from Corey Huinker. --- doc/src/sgml/ref/alter_table.sgml | 8 ++++++-- 1 file changed, 6 insertions(+), 2 deletions(-) diff --git a/doc/src/sgml/ref/alter_table.sgml b/doc/src/sgml/ref/alter_table.sgml index da431f8369..be857882bb 100644 --- a/doc/src/sgml/ref/alter_table.sgml +++ b/doc/src/sgml/ref/alter_table.sgml @@ -172,9 +172,13 @@ ALTER TABLE [ IF EXISTS ] <replaceable class="PARAMETER">name</replaceable> </para> <para> - If this table is a partition, one cannot perform <literal>DROP NOT NULL</> + If this table is a partition, one cannot perform <literal>DROP NOT NULL</literal> on a column if it is marked <literal>NOT NULL</literal> in the parent - table. + table. To drop the <literal>NOT NULL</literal> constraint from all the + partitions, perform <literal>DROP NOT NULL</literal> on the parent + table. One might however want to set it for only some partitions, + which is possible by doing <literal>SET NOT NULL</literal> on individual + partitions. </para> </listitem> </varlistentry> -- 2.11.0 --------------89FC639615756AE2477DE3D6 Content-Type: text/plain Content-Disposition: inline Content-Transfer-Encoding: 8bit MIME-Version: 1.0 -- Sent via pgsql-hackers mailing list ([email protected]) To make changes to your subscription: http://www.postgresql.org/mailpref/pgsql-hackers --------------89FC639615756AE2477DE3D6-- ^ permalink raw reply [nested|flat] 53+ messages in thread
* [PATCH 4/4] Add a note about DROP NOT NULL and partitions @ 2017-02-10 06:03 amit <[email protected]> 0 siblings, 0 replies; 53+ messages in thread From: amit @ 2017-02-10 06:03 UTC (permalink / raw) On the ALTER TABLE refpage, it seems better to mention how to drop drop the not null constraint of a partition's column. Per suggestion from Corey Huinker. --- doc/src/sgml/ref/alter_table.sgml | 8 ++++++-- 1 file changed, 6 insertions(+), 2 deletions(-) diff --git a/doc/src/sgml/ref/alter_table.sgml b/doc/src/sgml/ref/alter_table.sgml index da431f8369..be857882bb 100644 --- a/doc/src/sgml/ref/alter_table.sgml +++ b/doc/src/sgml/ref/alter_table.sgml @@ -172,9 +172,13 @@ ALTER TABLE [ IF EXISTS ] <replaceable class="PARAMETER">name</replaceable> </para> <para> - If this table is a partition, one cannot perform <literal>DROP NOT NULL</> + If this table is a partition, one cannot perform <literal>DROP NOT NULL</literal> on a column if it is marked <literal>NOT NULL</literal> in the parent - table. + table. To drop the <literal>NOT NULL</literal> constraint from all the + partitions, perform <literal>DROP NOT NULL</literal> on the parent + table. One might however want to set it for only some partitions, + which is possible by doing <literal>SET NOT NULL</literal> on individual + partitions. </para> </listitem> </varlistentry> -- 2.11.0 --------------89FC639615756AE2477DE3D6 Content-Type: text/plain Content-Disposition: inline Content-Transfer-Encoding: 8bit MIME-Version: 1.0 -- Sent via pgsql-hackers mailing list ([email protected]) To make changes to your subscription: http://www.postgresql.org/mailpref/pgsql-hackers --------------89FC639615756AE2477DE3D6-- ^ permalink raw reply [nested|flat] 53+ messages in thread
* [PATCH 2/3] Add a note about DROP NOT NULL and partitions @ 2017-02-10 06:03 amit <[email protected]> 0 siblings, 0 replies; 53+ messages in thread From: amit @ 2017-02-10 06:03 UTC (permalink / raw) On the ALTER TABLE refpage, it seems better to mention how to drop drop the not null constraint of a partition's column. Per suggestion from Corey Huinker. --- doc/src/sgml/ref/alter_table.sgml | 9 +++++++-- 1 file changed, 7 insertions(+), 2 deletions(-) diff --git a/doc/src/sgml/ref/alter_table.sgml b/doc/src/sgml/ref/alter_table.sgml index 077c00373d..b6be3a0dcb 100644 --- a/doc/src/sgml/ref/alter_table.sgml +++ b/doc/src/sgml/ref/alter_table.sgml @@ -172,9 +172,14 @@ ALTER TABLE [ IF EXISTS ] <replaceable class="PARAMETER">name</replaceable> </para> <para> - If this table is a partition, one cannot perform <literal>DROP NOT NULL</> + If this table is a partition, one cannot perform <literal>DROP NOT NULL</literal> on a column if it is marked <literal>NOT NULL</literal> in the parent - table. + table. To drop the <literal>NOT NULL</literal> constraint from all the + partitions, perform <literal>DROP NOT NULL</literal> on the parent + table. Even if there is no <literal>NOT NULL</> constraint on the + parent, such a constraint can still be added to individual partitions, + if desired; that is, the children can disallow nulls even if the parent + allows them, but not the other way around. </para> </listitem> </varlistentry> -- 2.11.0 --------------19C79A137EF2D0DB3BE72F79 Content-Type: text/x-diff; name="0003-Listify-a-note-on-the-CREATE-TABLE-page.patch" Content-Transfer-Encoding: 7bit Content-Disposition: attachment; filename="0003-Listify-a-note-on-the-CREATE-TABLE-page.patch" ^ permalink raw reply [nested|flat] 53+ messages in thread
* [PATCH 2/3] Add a note about DROP NOT NULL and partitions @ 2017-02-10 06:03 amit <[email protected]> 0 siblings, 0 replies; 53+ messages in thread From: amit @ 2017-02-10 06:03 UTC (permalink / raw) On the ALTER TABLE refpage, it seems better to mention how to drop drop the not null constraint of a partition's column. Per suggestion from Corey Huinker. --- doc/src/sgml/ref/alter_table.sgml | 8 ++++++-- 1 file changed, 6 insertions(+), 2 deletions(-) diff --git a/doc/src/sgml/ref/alter_table.sgml b/doc/src/sgml/ref/alter_table.sgml index da431f8369..be857882bb 100644 --- a/doc/src/sgml/ref/alter_table.sgml +++ b/doc/src/sgml/ref/alter_table.sgml @@ -172,9 +172,13 @@ ALTER TABLE [ IF EXISTS ] <replaceable class="PARAMETER">name</replaceable> </para> <para> - If this table is a partition, one cannot perform <literal>DROP NOT NULL</> + If this table is a partition, one cannot perform <literal>DROP NOT NULL</literal> on a column if it is marked <literal>NOT NULL</literal> in the parent - table. + table. To drop the <literal>NOT NULL</literal> constraint from all the + partitions, perform <literal>DROP NOT NULL</literal> on the parent + table. One might however want to set it for only some partitions, + which is possible by doing <literal>SET NOT NULL</literal> on individual + partitions. </para> </listitem> </varlistentry> -- 2.11.0 --------------434C61868FD2E7C005F82712 Content-Type: text/x-diff; name="0003-Listify-a-note-on-the-CREATE-TABLE-page.patch" Content-Transfer-Encoding: 7bit Content-Disposition: attachment; filename="0003-Listify-a-note-on-the-CREATE-TABLE-page.patch" ^ permalink raw reply [nested|flat] 53+ messages in thread
* [PATCH 2/3] Add a note about DROP NOT NULL and partitions @ 2017-02-10 06:03 amit <[email protected]> 0 siblings, 0 replies; 53+ messages in thread From: amit @ 2017-02-10 06:03 UTC (permalink / raw) On the ALTER TABLE refpage, it seems better to mention how to drop drop the not null constraint of a partition's column. Per suggestion from Corey Huinker. --- doc/src/sgml/ref/alter_table.sgml | 8 ++++++-- 1 file changed, 6 insertions(+), 2 deletions(-) diff --git a/doc/src/sgml/ref/alter_table.sgml b/doc/src/sgml/ref/alter_table.sgml index da431f8369..be857882bb 100644 --- a/doc/src/sgml/ref/alter_table.sgml +++ b/doc/src/sgml/ref/alter_table.sgml @@ -172,9 +172,13 @@ ALTER TABLE [ IF EXISTS ] <replaceable class="PARAMETER">name</replaceable> </para> <para> - If this table is a partition, one cannot perform <literal>DROP NOT NULL</> + If this table is a partition, one cannot perform <literal>DROP NOT NULL</literal> on a column if it is marked <literal>NOT NULL</literal> in the parent - table. + table. To drop the <literal>NOT NULL</literal> constraint from all the + partitions, perform <literal>DROP NOT NULL</literal> on the parent + table. One might however want to set it for only some partitions, + which is possible by doing <literal>SET NOT NULL</literal> on individual + partitions. </para> </listitem> </varlistentry> -- 2.11.0 --------------434C61868FD2E7C005F82712 Content-Type: text/x-diff; name="0003-Listify-a-note-on-the-CREATE-TABLE-page.patch" Content-Transfer-Encoding: 7bit Content-Disposition: attachment; filename="0003-Listify-a-note-on-the-CREATE-TABLE-page.patch" ^ permalink raw reply [nested|flat] 53+ messages in thread
* [PATCH 2/3] Add a note about DROP NOT NULL and partitions @ 2017-02-10 06:03 amit <[email protected]> 0 siblings, 0 replies; 53+ messages in thread From: amit @ 2017-02-10 06:03 UTC (permalink / raw) On the ALTER TABLE refpage, it seems better to mention how to drop drop the not null constraint of a partition's column. Per suggestion from Corey Huinker. --- doc/src/sgml/ref/alter_table.sgml | 9 +++++++-- 1 file changed, 7 insertions(+), 2 deletions(-) diff --git a/doc/src/sgml/ref/alter_table.sgml b/doc/src/sgml/ref/alter_table.sgml index 077c00373d..b6be3a0dcb 100644 --- a/doc/src/sgml/ref/alter_table.sgml +++ b/doc/src/sgml/ref/alter_table.sgml @@ -172,9 +172,14 @@ ALTER TABLE [ IF EXISTS ] <replaceable class="PARAMETER">name</replaceable> </para> <para> - If this table is a partition, one cannot perform <literal>DROP NOT NULL</> + If this table is a partition, one cannot perform <literal>DROP NOT NULL</literal> on a column if it is marked <literal>NOT NULL</literal> in the parent - table. + table. To drop the <literal>NOT NULL</literal> constraint from all the + partitions, perform <literal>DROP NOT NULL</literal> on the parent + table. Even if there is no <literal>NOT NULL</> constraint on the + parent, such a constraint can still be added to individual partitions, + if desired; that is, the children can disallow nulls even if the parent + allows them, but not the other way around. </para> </listitem> </varlistentry> -- 2.11.0 --------------19C79A137EF2D0DB3BE72F79 Content-Type: text/x-diff; name="0003-Listify-a-note-on-the-CREATE-TABLE-page.patch" Content-Transfer-Encoding: 7bit Content-Disposition: attachment; filename="0003-Listify-a-note-on-the-CREATE-TABLE-page.patch" ^ permalink raw reply [nested|flat] 53+ messages in thread
* [PATCH 2/3] Add a note about DROP NOT NULL and partitions @ 2017-02-10 06:03 amit <[email protected]> 0 siblings, 0 replies; 53+ messages in thread From: amit @ 2017-02-10 06:03 UTC (permalink / raw) On the ALTER TABLE refpage, it seems better to mention how to drop drop the not null constraint of a partition's column. Per suggestion from Corey Huinker. --- doc/src/sgml/ref/alter_table.sgml | 8 ++++++-- 1 file changed, 6 insertions(+), 2 deletions(-) diff --git a/doc/src/sgml/ref/alter_table.sgml b/doc/src/sgml/ref/alter_table.sgml index da431f8369..be857882bb 100644 --- a/doc/src/sgml/ref/alter_table.sgml +++ b/doc/src/sgml/ref/alter_table.sgml @@ -172,9 +172,13 @@ ALTER TABLE [ IF EXISTS ] <replaceable class="PARAMETER">name</replaceable> </para> <para> - If this table is a partition, one cannot perform <literal>DROP NOT NULL</> + If this table is a partition, one cannot perform <literal>DROP NOT NULL</literal> on a column if it is marked <literal>NOT NULL</literal> in the parent - table. + table. To drop the <literal>NOT NULL</literal> constraint from all the + partitions, perform <literal>DROP NOT NULL</literal> on the parent + table. One might however want to set it for only some partitions, + which is possible by doing <literal>SET NOT NULL</literal> on individual + partitions. </para> </listitem> </varlistentry> -- 2.11.0 --------------434C61868FD2E7C005F82712 Content-Type: text/x-diff; name="0003-Listify-a-note-on-the-CREATE-TABLE-page.patch" Content-Transfer-Encoding: 7bit Content-Disposition: attachment; filename="0003-Listify-a-note-on-the-CREATE-TABLE-page.patch" ^ permalink raw reply [nested|flat] 53+ messages in thread
* [PATCH 4/4] Add a note about DROP NOT NULL and partitions @ 2017-02-10 06:03 amit <[email protected]> 0 siblings, 0 replies; 53+ messages in thread From: amit @ 2017-02-10 06:03 UTC (permalink / raw) On the ALTER TABLE refpage, it seems better to mention how to drop drop the not null constraint of a partition's column. Per suggestion from Corey Huinker. --- doc/src/sgml/ref/alter_table.sgml | 8 ++++++-- 1 file changed, 6 insertions(+), 2 deletions(-) diff --git a/doc/src/sgml/ref/alter_table.sgml b/doc/src/sgml/ref/alter_table.sgml index da431f8369..be857882bb 100644 --- a/doc/src/sgml/ref/alter_table.sgml +++ b/doc/src/sgml/ref/alter_table.sgml @@ -172,9 +172,13 @@ ALTER TABLE [ IF EXISTS ] <replaceable class="PARAMETER">name</replaceable> </para> <para> - If this table is a partition, one cannot perform <literal>DROP NOT NULL</> + If this table is a partition, one cannot perform <literal>DROP NOT NULL</literal> on a column if it is marked <literal>NOT NULL</literal> in the parent - table. + table. To drop the <literal>NOT NULL</literal> constraint from all the + partitions, perform <literal>DROP NOT NULL</literal> on the parent + table. One might however want to set it for only some partitions, + which is possible by doing <literal>SET NOT NULL</literal> on individual + partitions. </para> </listitem> </varlistentry> -- 2.11.0 --------------89FC639615756AE2477DE3D6 Content-Type: text/plain Content-Disposition: inline Content-Transfer-Encoding: 8bit MIME-Version: 1.0 -- Sent via pgsql-hackers mailing list ([email protected]) To make changes to your subscription: http://www.postgresql.org/mailpref/pgsql-hackers --------------89FC639615756AE2477DE3D6-- ^ permalink raw reply [nested|flat] 53+ messages in thread
* [PATCH 2/3] Add a note about DROP NOT NULL and partitions @ 2017-02-10 06:03 amit <[email protected]> 0 siblings, 0 replies; 53+ messages in thread From: amit @ 2017-02-10 06:03 UTC (permalink / raw) On the ALTER TABLE refpage, it seems better to mention how to drop drop the not null constraint of a partition's column. Per suggestion from Corey Huinker. --- doc/src/sgml/ref/alter_table.sgml | 9 +++++++-- 1 file changed, 7 insertions(+), 2 deletions(-) diff --git a/doc/src/sgml/ref/alter_table.sgml b/doc/src/sgml/ref/alter_table.sgml index 077c00373d..b6be3a0dcb 100644 --- a/doc/src/sgml/ref/alter_table.sgml +++ b/doc/src/sgml/ref/alter_table.sgml @@ -172,9 +172,14 @@ ALTER TABLE [ IF EXISTS ] <replaceable class="PARAMETER">name</replaceable> </para> <para> - If this table is a partition, one cannot perform <literal>DROP NOT NULL</> + If this table is a partition, one cannot perform <literal>DROP NOT NULL</literal> on a column if it is marked <literal>NOT NULL</literal> in the parent - table. + table. To drop the <literal>NOT NULL</literal> constraint from all the + partitions, perform <literal>DROP NOT NULL</literal> on the parent + table. Even if there is no <literal>NOT NULL</> constraint on the + parent, such a constraint can still be added to individual partitions, + if desired; that is, the children can disallow nulls even if the parent + allows them, but not the other way around. </para> </listitem> </varlistentry> -- 2.11.0 --------------19C79A137EF2D0DB3BE72F79 Content-Type: text/x-diff; name="0003-Listify-a-note-on-the-CREATE-TABLE-page.patch" Content-Transfer-Encoding: 7bit Content-Disposition: attachment; filename="0003-Listify-a-note-on-the-CREATE-TABLE-page.patch" ^ permalink raw reply [nested|flat] 53+ messages in thread
* [PATCH 2/3] Add a note about DROP NOT NULL and partitions @ 2017-02-10 06:03 amit <[email protected]> 0 siblings, 0 replies; 53+ messages in thread From: amit @ 2017-02-10 06:03 UTC (permalink / raw) On the ALTER TABLE refpage, it seems better to mention how to drop drop the not null constraint of a partition's column. Per suggestion from Corey Huinker. --- doc/src/sgml/ref/alter_table.sgml | 8 ++++++-- 1 file changed, 6 insertions(+), 2 deletions(-) diff --git a/doc/src/sgml/ref/alter_table.sgml b/doc/src/sgml/ref/alter_table.sgml index da431f8369..be857882bb 100644 --- a/doc/src/sgml/ref/alter_table.sgml +++ b/doc/src/sgml/ref/alter_table.sgml @@ -172,9 +172,13 @@ ALTER TABLE [ IF EXISTS ] <replaceable class="PARAMETER">name</replaceable> </para> <para> - If this table is a partition, one cannot perform <literal>DROP NOT NULL</> + If this table is a partition, one cannot perform <literal>DROP NOT NULL</literal> on a column if it is marked <literal>NOT NULL</literal> in the parent - table. + table. To drop the <literal>NOT NULL</literal> constraint from all the + partitions, perform <literal>DROP NOT NULL</literal> on the parent + table. One might however want to set it for only some partitions, + which is possible by doing <literal>SET NOT NULL</literal> on individual + partitions. </para> </listitem> </varlistentry> -- 2.11.0 --------------434C61868FD2E7C005F82712 Content-Type: text/x-diff; name="0003-Listify-a-note-on-the-CREATE-TABLE-page.patch" Content-Transfer-Encoding: 7bit Content-Disposition: attachment; filename="0003-Listify-a-note-on-the-CREATE-TABLE-page.patch" ^ permalink raw reply [nested|flat] 53+ messages in thread
* [PATCH 4/4] Add a note about DROP NOT NULL and partitions @ 2017-02-10 06:03 amit <[email protected]> 0 siblings, 0 replies; 53+ messages in thread From: amit @ 2017-02-10 06:03 UTC (permalink / raw) On the ALTER TABLE refpage, it seems better to mention how to drop drop the not null constraint of a partition's column. Per suggestion from Corey Huinker. --- doc/src/sgml/ref/alter_table.sgml | 8 ++++++-- 1 file changed, 6 insertions(+), 2 deletions(-) diff --git a/doc/src/sgml/ref/alter_table.sgml b/doc/src/sgml/ref/alter_table.sgml index da431f8369..be857882bb 100644 --- a/doc/src/sgml/ref/alter_table.sgml +++ b/doc/src/sgml/ref/alter_table.sgml @@ -172,9 +172,13 @@ ALTER TABLE [ IF EXISTS ] <replaceable class="PARAMETER">name</replaceable> </para> <para> - If this table is a partition, one cannot perform <literal>DROP NOT NULL</> + If this table is a partition, one cannot perform <literal>DROP NOT NULL</literal> on a column if it is marked <literal>NOT NULL</literal> in the parent - table. + table. To drop the <literal>NOT NULL</literal> constraint from all the + partitions, perform <literal>DROP NOT NULL</literal> on the parent + table. One might however want to set it for only some partitions, + which is possible by doing <literal>SET NOT NULL</literal> on individual + partitions. </para> </listitem> </varlistentry> -- 2.11.0 --------------89FC639615756AE2477DE3D6 Content-Type: text/plain Content-Disposition: inline Content-Transfer-Encoding: 8bit MIME-Version: 1.0 -- Sent via pgsql-hackers mailing list ([email protected]) To make changes to your subscription: http://www.postgresql.org/mailpref/pgsql-hackers --------------89FC639615756AE2477DE3D6-- ^ permalink raw reply [nested|flat] 53+ messages in thread
* [PATCH 4/4] Add a note about DROP NOT NULL and partitions @ 2017-02-10 06:03 amit <[email protected]> 0 siblings, 0 replies; 53+ messages in thread From: amit @ 2017-02-10 06:03 UTC (permalink / raw) On the ALTER TABLE refpage, it seems better to mention how to drop drop the not null constraint of a partition's column. Per suggestion from Corey Huinker. --- doc/src/sgml/ref/alter_table.sgml | 8 ++++++-- 1 file changed, 6 insertions(+), 2 deletions(-) diff --git a/doc/src/sgml/ref/alter_table.sgml b/doc/src/sgml/ref/alter_table.sgml index da431f8369..be857882bb 100644 --- a/doc/src/sgml/ref/alter_table.sgml +++ b/doc/src/sgml/ref/alter_table.sgml @@ -172,9 +172,13 @@ ALTER TABLE [ IF EXISTS ] <replaceable class="PARAMETER">name</replaceable> </para> <para> - If this table is a partition, one cannot perform <literal>DROP NOT NULL</> + If this table is a partition, one cannot perform <literal>DROP NOT NULL</literal> on a column if it is marked <literal>NOT NULL</literal> in the parent - table. + table. To drop the <literal>NOT NULL</literal> constraint from all the + partitions, perform <literal>DROP NOT NULL</literal> on the parent + table. One might however want to set it for only some partitions, + which is possible by doing <literal>SET NOT NULL</literal> on individual + partitions. </para> </listitem> </varlistentry> -- 2.11.0 --------------89FC639615756AE2477DE3D6 Content-Type: text/plain Content-Disposition: inline Content-Transfer-Encoding: 8bit MIME-Version: 1.0 -- Sent via pgsql-hackers mailing list ([email protected]) To make changes to your subscription: http://www.postgresql.org/mailpref/pgsql-hackers --------------89FC639615756AE2477DE3D6-- ^ permalink raw reply [nested|flat] 53+ messages in thread
* [PATCH 2/3] Add a note about DROP NOT NULL and partitions @ 2017-02-10 06:03 amit <[email protected]> 0 siblings, 0 replies; 53+ messages in thread From: amit @ 2017-02-10 06:03 UTC (permalink / raw) On the ALTER TABLE refpage, it seems better to mention how to drop drop the not null constraint of a partition's column. Per suggestion from Corey Huinker. --- doc/src/sgml/ref/alter_table.sgml | 9 +++++++-- 1 file changed, 7 insertions(+), 2 deletions(-) diff --git a/doc/src/sgml/ref/alter_table.sgml b/doc/src/sgml/ref/alter_table.sgml index 077c00373d..b6be3a0dcb 100644 --- a/doc/src/sgml/ref/alter_table.sgml +++ b/doc/src/sgml/ref/alter_table.sgml @@ -172,9 +172,14 @@ ALTER TABLE [ IF EXISTS ] <replaceable class="PARAMETER">name</replaceable> </para> <para> - If this table is a partition, one cannot perform <literal>DROP NOT NULL</> + If this table is a partition, one cannot perform <literal>DROP NOT NULL</literal> on a column if it is marked <literal>NOT NULL</literal> in the parent - table. + table. To drop the <literal>NOT NULL</literal> constraint from all the + partitions, perform <literal>DROP NOT NULL</literal> on the parent + table. Even if there is no <literal>NOT NULL</> constraint on the + parent, such a constraint can still be added to individual partitions, + if desired; that is, the children can disallow nulls even if the parent + allows them, but not the other way around. </para> </listitem> </varlistentry> -- 2.11.0 --------------19C79A137EF2D0DB3BE72F79 Content-Type: text/x-diff; name="0003-Listify-a-note-on-the-CREATE-TABLE-page.patch" Content-Transfer-Encoding: 7bit Content-Disposition: attachment; filename="0003-Listify-a-note-on-the-CREATE-TABLE-page.patch" ^ permalink raw reply [nested|flat] 53+ messages in thread
* [PATCH 2/3] Add a note about DROP NOT NULL and partitions @ 2017-02-10 06:03 amit <[email protected]> 0 siblings, 0 replies; 53+ messages in thread From: amit @ 2017-02-10 06:03 UTC (permalink / raw) On the ALTER TABLE refpage, it seems better to mention how to drop drop the not null constraint of a partition's column. Per suggestion from Corey Huinker. --- doc/src/sgml/ref/alter_table.sgml | 8 ++++++-- 1 file changed, 6 insertions(+), 2 deletions(-) diff --git a/doc/src/sgml/ref/alter_table.sgml b/doc/src/sgml/ref/alter_table.sgml index da431f8369..be857882bb 100644 --- a/doc/src/sgml/ref/alter_table.sgml +++ b/doc/src/sgml/ref/alter_table.sgml @@ -172,9 +172,13 @@ ALTER TABLE [ IF EXISTS ] <replaceable class="PARAMETER">name</replaceable> </para> <para> - If this table is a partition, one cannot perform <literal>DROP NOT NULL</> + If this table is a partition, one cannot perform <literal>DROP NOT NULL</literal> on a column if it is marked <literal>NOT NULL</literal> in the parent - table. + table. To drop the <literal>NOT NULL</literal> constraint from all the + partitions, perform <literal>DROP NOT NULL</literal> on the parent + table. One might however want to set it for only some partitions, + which is possible by doing <literal>SET NOT NULL</literal> on individual + partitions. </para> </listitem> </varlistentry> -- 2.11.0 --------------434C61868FD2E7C005F82712 Content-Type: text/x-diff; name="0003-Listify-a-note-on-the-CREATE-TABLE-page.patch" Content-Transfer-Encoding: 7bit Content-Disposition: attachment; filename="0003-Listify-a-note-on-the-CREATE-TABLE-page.patch" ^ permalink raw reply [nested|flat] 53+ messages in thread
* [PATCH 2/3] Add a note about DROP NOT NULL and partitions @ 2017-02-10 06:03 amit <[email protected]> 0 siblings, 0 replies; 53+ messages in thread From: amit @ 2017-02-10 06:03 UTC (permalink / raw) On the ALTER TABLE refpage, it seems better to mention how to drop drop the not null constraint of a partition's column. Per suggestion from Corey Huinker. --- doc/src/sgml/ref/alter_table.sgml | 8 ++++++-- 1 file changed, 6 insertions(+), 2 deletions(-) diff --git a/doc/src/sgml/ref/alter_table.sgml b/doc/src/sgml/ref/alter_table.sgml index da431f8369..be857882bb 100644 --- a/doc/src/sgml/ref/alter_table.sgml +++ b/doc/src/sgml/ref/alter_table.sgml @@ -172,9 +172,13 @@ ALTER TABLE [ IF EXISTS ] <replaceable class="PARAMETER">name</replaceable> </para> <para> - If this table is a partition, one cannot perform <literal>DROP NOT NULL</> + If this table is a partition, one cannot perform <literal>DROP NOT NULL</literal> on a column if it is marked <literal>NOT NULL</literal> in the parent - table. + table. To drop the <literal>NOT NULL</literal> constraint from all the + partitions, perform <literal>DROP NOT NULL</literal> on the parent + table. One might however want to set it for only some partitions, + which is possible by doing <literal>SET NOT NULL</literal> on individual + partitions. </para> </listitem> </varlistentry> -- 2.11.0 --------------434C61868FD2E7C005F82712 Content-Type: text/x-diff; name="0003-Listify-a-note-on-the-CREATE-TABLE-page.patch" Content-Transfer-Encoding: 7bit Content-Disposition: attachment; filename="0003-Listify-a-note-on-the-CREATE-TABLE-page.patch" ^ permalink raw reply [nested|flat] 53+ messages in thread
* [PATCH 2/3] Add a note about DROP NOT NULL and partitions @ 2017-02-10 06:03 amit <[email protected]> 0 siblings, 0 replies; 53+ messages in thread From: amit @ 2017-02-10 06:03 UTC (permalink / raw) On the ALTER TABLE refpage, it seems better to mention how to drop drop the not null constraint of a partition's column. Per suggestion from Corey Huinker. --- doc/src/sgml/ref/alter_table.sgml | 8 ++++++-- 1 file changed, 6 insertions(+), 2 deletions(-) diff --git a/doc/src/sgml/ref/alter_table.sgml b/doc/src/sgml/ref/alter_table.sgml index da431f8369..be857882bb 100644 --- a/doc/src/sgml/ref/alter_table.sgml +++ b/doc/src/sgml/ref/alter_table.sgml @@ -172,9 +172,13 @@ ALTER TABLE [ IF EXISTS ] <replaceable class="PARAMETER">name</replaceable> </para> <para> - If this table is a partition, one cannot perform <literal>DROP NOT NULL</> + If this table is a partition, one cannot perform <literal>DROP NOT NULL</literal> on a column if it is marked <literal>NOT NULL</literal> in the parent - table. + table. To drop the <literal>NOT NULL</literal> constraint from all the + partitions, perform <literal>DROP NOT NULL</literal> on the parent + table. One might however want to set it for only some partitions, + which is possible by doing <literal>SET NOT NULL</literal> on individual + partitions. </para> </listitem> </varlistentry> -- 2.11.0 --------------434C61868FD2E7C005F82712 Content-Type: text/x-diff; name="0003-Listify-a-note-on-the-CREATE-TABLE-page.patch" Content-Transfer-Encoding: 7bit Content-Disposition: attachment; filename="0003-Listify-a-note-on-the-CREATE-TABLE-page.patch" ^ permalink raw reply [nested|flat] 53+ messages in thread
* [PATCH 2/3] Add a note about DROP NOT NULL and partitions @ 2017-02-10 06:03 amit <[email protected]> 0 siblings, 0 replies; 53+ messages in thread From: amit @ 2017-02-10 06:03 UTC (permalink / raw) On the ALTER TABLE refpage, it seems better to mention how to drop drop the not null constraint of a partition's column. Per suggestion from Corey Huinker. --- doc/src/sgml/ref/alter_table.sgml | 8 ++++++-- 1 file changed, 6 insertions(+), 2 deletions(-) diff --git a/doc/src/sgml/ref/alter_table.sgml b/doc/src/sgml/ref/alter_table.sgml index da431f8369..be857882bb 100644 --- a/doc/src/sgml/ref/alter_table.sgml +++ b/doc/src/sgml/ref/alter_table.sgml @@ -172,9 +172,13 @@ ALTER TABLE [ IF EXISTS ] <replaceable class="PARAMETER">name</replaceable> </para> <para> - If this table is a partition, one cannot perform <literal>DROP NOT NULL</> + If this table is a partition, one cannot perform <literal>DROP NOT NULL</literal> on a column if it is marked <literal>NOT NULL</literal> in the parent - table. + table. To drop the <literal>NOT NULL</literal> constraint from all the + partitions, perform <literal>DROP NOT NULL</literal> on the parent + table. One might however want to set it for only some partitions, + which is possible by doing <literal>SET NOT NULL</literal> on individual + partitions. </para> </listitem> </varlistentry> -- 2.11.0 --------------434C61868FD2E7C005F82712 Content-Type: text/x-diff; name="0003-Listify-a-note-on-the-CREATE-TABLE-page.patch" Content-Transfer-Encoding: 7bit Content-Disposition: attachment; filename="0003-Listify-a-note-on-the-CREATE-TABLE-page.patch" ^ permalink raw reply [nested|flat] 53+ messages in thread
* [PATCH 2/3] Add a note about DROP NOT NULL and partitions @ 2017-02-10 06:03 amit <[email protected]> 0 siblings, 0 replies; 53+ messages in thread From: amit @ 2017-02-10 06:03 UTC (permalink / raw) On the ALTER TABLE refpage, it seems better to mention how to drop drop the not null constraint of a partition's column. Per suggestion from Corey Huinker. --- doc/src/sgml/ref/alter_table.sgml | 9 +++++++-- 1 file changed, 7 insertions(+), 2 deletions(-) diff --git a/doc/src/sgml/ref/alter_table.sgml b/doc/src/sgml/ref/alter_table.sgml index 077c00373d..b6be3a0dcb 100644 --- a/doc/src/sgml/ref/alter_table.sgml +++ b/doc/src/sgml/ref/alter_table.sgml @@ -172,9 +172,14 @@ ALTER TABLE [ IF EXISTS ] <replaceable class="PARAMETER">name</replaceable> </para> <para> - If this table is a partition, one cannot perform <literal>DROP NOT NULL</> + If this table is a partition, one cannot perform <literal>DROP NOT NULL</literal> on a column if it is marked <literal>NOT NULL</literal> in the parent - table. + table. To drop the <literal>NOT NULL</literal> constraint from all the + partitions, perform <literal>DROP NOT NULL</literal> on the parent + table. Even if there is no <literal>NOT NULL</> constraint on the + parent, such a constraint can still be added to individual partitions, + if desired; that is, the children can disallow nulls even if the parent + allows them, but not the other way around. </para> </listitem> </varlistentry> -- 2.11.0 --------------19C79A137EF2D0DB3BE72F79 Content-Type: text/x-diff; name="0003-Listify-a-note-on-the-CREATE-TABLE-page.patch" Content-Transfer-Encoding: 7bit Content-Disposition: attachment; filename="0003-Listify-a-note-on-the-CREATE-TABLE-page.patch" ^ permalink raw reply [nested|flat] 53+ messages in thread
* [PATCH 4/4] Add a note about DROP NOT NULL and partitions @ 2017-02-10 06:03 amit <[email protected]> 0 siblings, 0 replies; 53+ messages in thread From: amit @ 2017-02-10 06:03 UTC (permalink / raw) On the ALTER TABLE refpage, it seems better to mention how to drop drop the not null constraint of a partition's column. Per suggestion from Corey Huinker. --- doc/src/sgml/ref/alter_table.sgml | 8 ++++++-- 1 file changed, 6 insertions(+), 2 deletions(-) diff --git a/doc/src/sgml/ref/alter_table.sgml b/doc/src/sgml/ref/alter_table.sgml index da431f8369..be857882bb 100644 --- a/doc/src/sgml/ref/alter_table.sgml +++ b/doc/src/sgml/ref/alter_table.sgml @@ -172,9 +172,13 @@ ALTER TABLE [ IF EXISTS ] <replaceable class="PARAMETER">name</replaceable> </para> <para> - If this table is a partition, one cannot perform <literal>DROP NOT NULL</> + If this table is a partition, one cannot perform <literal>DROP NOT NULL</literal> on a column if it is marked <literal>NOT NULL</literal> in the parent - table. + table. To drop the <literal>NOT NULL</literal> constraint from all the + partitions, perform <literal>DROP NOT NULL</literal> on the parent + table. One might however want to set it for only some partitions, + which is possible by doing <literal>SET NOT NULL</literal> on individual + partitions. </para> </listitem> </varlistentry> -- 2.11.0 --------------89FC639615756AE2477DE3D6 Content-Type: text/plain Content-Disposition: inline Content-Transfer-Encoding: 8bit MIME-Version: 1.0 -- Sent via pgsql-hackers mailing list ([email protected]) To make changes to your subscription: http://www.postgresql.org/mailpref/pgsql-hackers --------------89FC639615756AE2477DE3D6-- ^ permalink raw reply [nested|flat] 53+ messages in thread
* [PATCH 2/3] Add a note about DROP NOT NULL and partitions @ 2017-02-10 06:03 amit <[email protected]> 0 siblings, 0 replies; 53+ messages in thread From: amit @ 2017-02-10 06:03 UTC (permalink / raw) On the ALTER TABLE refpage, it seems better to mention how to drop drop the not null constraint of a partition's column. Per suggestion from Corey Huinker. --- doc/src/sgml/ref/alter_table.sgml | 8 ++++++-- 1 file changed, 6 insertions(+), 2 deletions(-) diff --git a/doc/src/sgml/ref/alter_table.sgml b/doc/src/sgml/ref/alter_table.sgml index da431f8369..be857882bb 100644 --- a/doc/src/sgml/ref/alter_table.sgml +++ b/doc/src/sgml/ref/alter_table.sgml @@ -172,9 +172,13 @@ ALTER TABLE [ IF EXISTS ] <replaceable class="PARAMETER">name</replaceable> </para> <para> - If this table is a partition, one cannot perform <literal>DROP NOT NULL</> + If this table is a partition, one cannot perform <literal>DROP NOT NULL</literal> on a column if it is marked <literal>NOT NULL</literal> in the parent - table. + table. To drop the <literal>NOT NULL</literal> constraint from all the + partitions, perform <literal>DROP NOT NULL</literal> on the parent + table. One might however want to set it for only some partitions, + which is possible by doing <literal>SET NOT NULL</literal> on individual + partitions. </para> </listitem> </varlistentry> -- 2.11.0 --------------434C61868FD2E7C005F82712 Content-Type: text/x-diff; name="0003-Listify-a-note-on-the-CREATE-TABLE-page.patch" Content-Transfer-Encoding: 7bit Content-Disposition: attachment; filename="0003-Listify-a-note-on-the-CREATE-TABLE-page.patch" ^ permalink raw reply [nested|flat] 53+ messages in thread
* [PATCH 2/3] Add a note about DROP NOT NULL and partitions @ 2017-02-10 06:03 amit <[email protected]> 0 siblings, 0 replies; 53+ messages in thread From: amit @ 2017-02-10 06:03 UTC (permalink / raw) On the ALTER TABLE refpage, it seems better to mention how to drop drop the not null constraint of a partition's column. Per suggestion from Corey Huinker. --- doc/src/sgml/ref/alter_table.sgml | 9 +++++++-- 1 file changed, 7 insertions(+), 2 deletions(-) diff --git a/doc/src/sgml/ref/alter_table.sgml b/doc/src/sgml/ref/alter_table.sgml index 077c00373d..b6be3a0dcb 100644 --- a/doc/src/sgml/ref/alter_table.sgml +++ b/doc/src/sgml/ref/alter_table.sgml @@ -172,9 +172,14 @@ ALTER TABLE [ IF EXISTS ] <replaceable class="PARAMETER">name</replaceable> </para> <para> - If this table is a partition, one cannot perform <literal>DROP NOT NULL</> + If this table is a partition, one cannot perform <literal>DROP NOT NULL</literal> on a column if it is marked <literal>NOT NULL</literal> in the parent - table. + table. To drop the <literal>NOT NULL</literal> constraint from all the + partitions, perform <literal>DROP NOT NULL</literal> on the parent + table. Even if there is no <literal>NOT NULL</> constraint on the + parent, such a constraint can still be added to individual partitions, + if desired; that is, the children can disallow nulls even if the parent + allows them, but not the other way around. </para> </listitem> </varlistentry> -- 2.11.0 --------------19C79A137EF2D0DB3BE72F79 Content-Type: text/x-diff; name="0003-Listify-a-note-on-the-CREATE-TABLE-page.patch" Content-Transfer-Encoding: 7bit Content-Disposition: attachment; filename="0003-Listify-a-note-on-the-CREATE-TABLE-page.patch" ^ permalink raw reply [nested|flat] 53+ messages in thread
* [PATCH 2/3] Add a note about DROP NOT NULL and partitions @ 2017-02-10 06:03 amit <[email protected]> 0 siblings, 0 replies; 53+ messages in thread From: amit @ 2017-02-10 06:03 UTC (permalink / raw) On the ALTER TABLE refpage, it seems better to mention how to drop drop the not null constraint of a partition's column. Per suggestion from Corey Huinker. --- doc/src/sgml/ref/alter_table.sgml | 8 ++++++-- 1 file changed, 6 insertions(+), 2 deletions(-) diff --git a/doc/src/sgml/ref/alter_table.sgml b/doc/src/sgml/ref/alter_table.sgml index da431f8369..be857882bb 100644 --- a/doc/src/sgml/ref/alter_table.sgml +++ b/doc/src/sgml/ref/alter_table.sgml @@ -172,9 +172,13 @@ ALTER TABLE [ IF EXISTS ] <replaceable class="PARAMETER">name</replaceable> </para> <para> - If this table is a partition, one cannot perform <literal>DROP NOT NULL</> + If this table is a partition, one cannot perform <literal>DROP NOT NULL</literal> on a column if it is marked <literal>NOT NULL</literal> in the parent - table. + table. To drop the <literal>NOT NULL</literal> constraint from all the + partitions, perform <literal>DROP NOT NULL</literal> on the parent + table. One might however want to set it for only some partitions, + which is possible by doing <literal>SET NOT NULL</literal> on individual + partitions. </para> </listitem> </varlistentry> -- 2.11.0 --------------434C61868FD2E7C005F82712 Content-Type: text/x-diff; name="0003-Listify-a-note-on-the-CREATE-TABLE-page.patch" Content-Transfer-Encoding: 7bit Content-Disposition: attachment; filename="0003-Listify-a-note-on-the-CREATE-TABLE-page.patch" ^ permalink raw reply [nested|flat] 53+ messages in thread
* [PATCH 2/3] Add a note about DROP NOT NULL and partitions @ 2017-02-10 06:03 amit <[email protected]> 0 siblings, 0 replies; 53+ messages in thread From: amit @ 2017-02-10 06:03 UTC (permalink / raw) On the ALTER TABLE refpage, it seems better to mention how to drop drop the not null constraint of a partition's column. Per suggestion from Corey Huinker. --- doc/src/sgml/ref/alter_table.sgml | 9 +++++++-- 1 file changed, 7 insertions(+), 2 deletions(-) diff --git a/doc/src/sgml/ref/alter_table.sgml b/doc/src/sgml/ref/alter_table.sgml index 077c00373d..b6be3a0dcb 100644 --- a/doc/src/sgml/ref/alter_table.sgml +++ b/doc/src/sgml/ref/alter_table.sgml @@ -172,9 +172,14 @@ ALTER TABLE [ IF EXISTS ] <replaceable class="PARAMETER">name</replaceable> </para> <para> - If this table is a partition, one cannot perform <literal>DROP NOT NULL</> + If this table is a partition, one cannot perform <literal>DROP NOT NULL</literal> on a column if it is marked <literal>NOT NULL</literal> in the parent - table. + table. To drop the <literal>NOT NULL</literal> constraint from all the + partitions, perform <literal>DROP NOT NULL</literal> on the parent + table. Even if there is no <literal>NOT NULL</> constraint on the + parent, such a constraint can still be added to individual partitions, + if desired; that is, the children can disallow nulls even if the parent + allows them, but not the other way around. </para> </listitem> </varlistentry> -- 2.11.0 --------------19C79A137EF2D0DB3BE72F79 Content-Type: text/x-diff; name="0003-Listify-a-note-on-the-CREATE-TABLE-page.patch" Content-Transfer-Encoding: 7bit Content-Disposition: attachment; filename="0003-Listify-a-note-on-the-CREATE-TABLE-page.patch" ^ permalink raw reply [nested|flat] 53+ messages in thread
* [PATCH 4/4] Add a note about DROP NOT NULL and partitions @ 2017-02-10 06:03 amit <[email protected]> 0 siblings, 0 replies; 53+ messages in thread From: amit @ 2017-02-10 06:03 UTC (permalink / raw) On the ALTER TABLE refpage, it seems better to mention how to drop drop the not null constraint of a partition's column. Per suggestion from Corey Huinker. --- doc/src/sgml/ref/alter_table.sgml | 8 ++++++-- 1 file changed, 6 insertions(+), 2 deletions(-) diff --git a/doc/src/sgml/ref/alter_table.sgml b/doc/src/sgml/ref/alter_table.sgml index da431f8369..be857882bb 100644 --- a/doc/src/sgml/ref/alter_table.sgml +++ b/doc/src/sgml/ref/alter_table.sgml @@ -172,9 +172,13 @@ ALTER TABLE [ IF EXISTS ] <replaceable class="PARAMETER">name</replaceable> </para> <para> - If this table is a partition, one cannot perform <literal>DROP NOT NULL</> + If this table is a partition, one cannot perform <literal>DROP NOT NULL</literal> on a column if it is marked <literal>NOT NULL</literal> in the parent - table. + table. To drop the <literal>NOT NULL</literal> constraint from all the + partitions, perform <literal>DROP NOT NULL</literal> on the parent + table. One might however want to set it for only some partitions, + which is possible by doing <literal>SET NOT NULL</literal> on individual + partitions. </para> </listitem> </varlistentry> -- 2.11.0 --------------89FC639615756AE2477DE3D6 Content-Type: text/plain Content-Disposition: inline Content-Transfer-Encoding: 8bit MIME-Version: 1.0 -- Sent via pgsql-hackers mailing list ([email protected]) To make changes to your subscription: http://www.postgresql.org/mailpref/pgsql-hackers --------------89FC639615756AE2477DE3D6-- ^ permalink raw reply [nested|flat] 53+ messages in thread
* [PATCH 2/3] Add a note about DROP NOT NULL and partitions @ 2017-02-10 06:03 amit <[email protected]> 0 siblings, 0 replies; 53+ messages in thread From: amit @ 2017-02-10 06:03 UTC (permalink / raw) On the ALTER TABLE refpage, it seems better to mention how to drop drop the not null constraint of a partition's column. Per suggestion from Corey Huinker. --- doc/src/sgml/ref/alter_table.sgml | 8 ++++++-- 1 file changed, 6 insertions(+), 2 deletions(-) diff --git a/doc/src/sgml/ref/alter_table.sgml b/doc/src/sgml/ref/alter_table.sgml index da431f8369..be857882bb 100644 --- a/doc/src/sgml/ref/alter_table.sgml +++ b/doc/src/sgml/ref/alter_table.sgml @@ -172,9 +172,13 @@ ALTER TABLE [ IF EXISTS ] <replaceable class="PARAMETER">name</replaceable> </para> <para> - If this table is a partition, one cannot perform <literal>DROP NOT NULL</> + If this table is a partition, one cannot perform <literal>DROP NOT NULL</literal> on a column if it is marked <literal>NOT NULL</literal> in the parent - table. + table. To drop the <literal>NOT NULL</literal> constraint from all the + partitions, perform <literal>DROP NOT NULL</literal> on the parent + table. One might however want to set it for only some partitions, + which is possible by doing <literal>SET NOT NULL</literal> on individual + partitions. </para> </listitem> </varlistentry> -- 2.11.0 --------------434C61868FD2E7C005F82712 Content-Type: text/x-diff; name="0003-Listify-a-note-on-the-CREATE-TABLE-page.patch" Content-Transfer-Encoding: 7bit Content-Disposition: attachment; filename="0003-Listify-a-note-on-the-CREATE-TABLE-page.patch" ^ permalink raw reply [nested|flat] 53+ messages in thread
* [PATCH 4/4] Add a note about DROP NOT NULL and partitions @ 2017-02-10 06:03 amit <[email protected]> 0 siblings, 0 replies; 53+ messages in thread From: amit @ 2017-02-10 06:03 UTC (permalink / raw) On the ALTER TABLE refpage, it seems better to mention how to drop drop the not null constraint of a partition's column. Per suggestion from Corey Huinker. --- doc/src/sgml/ref/alter_table.sgml | 8 ++++++-- 1 file changed, 6 insertions(+), 2 deletions(-) diff --git a/doc/src/sgml/ref/alter_table.sgml b/doc/src/sgml/ref/alter_table.sgml index da431f8369..be857882bb 100644 --- a/doc/src/sgml/ref/alter_table.sgml +++ b/doc/src/sgml/ref/alter_table.sgml @@ -172,9 +172,13 @@ ALTER TABLE [ IF EXISTS ] <replaceable class="PARAMETER">name</replaceable> </para> <para> - If this table is a partition, one cannot perform <literal>DROP NOT NULL</> + If this table is a partition, one cannot perform <literal>DROP NOT NULL</literal> on a column if it is marked <literal>NOT NULL</literal> in the parent - table. + table. To drop the <literal>NOT NULL</literal> constraint from all the + partitions, perform <literal>DROP NOT NULL</literal> on the parent + table. One might however want to set it for only some partitions, + which is possible by doing <literal>SET NOT NULL</literal> on individual + partitions. </para> </listitem> </varlistentry> -- 2.11.0 --------------89FC639615756AE2477DE3D6 Content-Type: text/plain Content-Disposition: inline Content-Transfer-Encoding: 8bit MIME-Version: 1.0 -- Sent via pgsql-hackers mailing list ([email protected]) To make changes to your subscription: http://www.postgresql.org/mailpref/pgsql-hackers --------------89FC639615756AE2477DE3D6-- ^ permalink raw reply [nested|flat] 53+ messages in thread
* [PATCH 2/3] Add a note about DROP NOT NULL and partitions @ 2017-02-10 06:03 amit <[email protected]> 0 siblings, 0 replies; 53+ messages in thread From: amit @ 2017-02-10 06:03 UTC (permalink / raw) On the ALTER TABLE refpage, it seems better to mention how to drop drop the not null constraint of a partition's column. Per suggestion from Corey Huinker. --- doc/src/sgml/ref/alter_table.sgml | 8 ++++++-- 1 file changed, 6 insertions(+), 2 deletions(-) diff --git a/doc/src/sgml/ref/alter_table.sgml b/doc/src/sgml/ref/alter_table.sgml index da431f8369..be857882bb 100644 --- a/doc/src/sgml/ref/alter_table.sgml +++ b/doc/src/sgml/ref/alter_table.sgml @@ -172,9 +172,13 @@ ALTER TABLE [ IF EXISTS ] <replaceable class="PARAMETER">name</replaceable> </para> <para> - If this table is a partition, one cannot perform <literal>DROP NOT NULL</> + If this table is a partition, one cannot perform <literal>DROP NOT NULL</literal> on a column if it is marked <literal>NOT NULL</literal> in the parent - table. + table. To drop the <literal>NOT NULL</literal> constraint from all the + partitions, perform <literal>DROP NOT NULL</literal> on the parent + table. One might however want to set it for only some partitions, + which is possible by doing <literal>SET NOT NULL</literal> on individual + partitions. </para> </listitem> </varlistentry> -- 2.11.0 --------------434C61868FD2E7C005F82712 Content-Type: text/x-diff; name="0003-Listify-a-note-on-the-CREATE-TABLE-page.patch" Content-Transfer-Encoding: 7bit Content-Disposition: attachment; filename="0003-Listify-a-note-on-the-CREATE-TABLE-page.patch" ^ permalink raw reply [nested|flat] 53+ messages in thread
* [PATCH 4/4] Add a note about DROP NOT NULL and partitions @ 2017-02-10 06:03 amit <[email protected]> 0 siblings, 0 replies; 53+ messages in thread From: amit @ 2017-02-10 06:03 UTC (permalink / raw) On the ALTER TABLE refpage, it seems better to mention how to drop drop the not null constraint of a partition's column. Per suggestion from Corey Huinker. --- doc/src/sgml/ref/alter_table.sgml | 8 ++++++-- 1 file changed, 6 insertions(+), 2 deletions(-) diff --git a/doc/src/sgml/ref/alter_table.sgml b/doc/src/sgml/ref/alter_table.sgml index da431f8369..be857882bb 100644 --- a/doc/src/sgml/ref/alter_table.sgml +++ b/doc/src/sgml/ref/alter_table.sgml @@ -172,9 +172,13 @@ ALTER TABLE [ IF EXISTS ] <replaceable class="PARAMETER">name</replaceable> </para> <para> - If this table is a partition, one cannot perform <literal>DROP NOT NULL</> + If this table is a partition, one cannot perform <literal>DROP NOT NULL</literal> on a column if it is marked <literal>NOT NULL</literal> in the parent - table. + table. To drop the <literal>NOT NULL</literal> constraint from all the + partitions, perform <literal>DROP NOT NULL</literal> on the parent + table. One might however want to set it for only some partitions, + which is possible by doing <literal>SET NOT NULL</literal> on individual + partitions. </para> </listitem> </varlistentry> -- 2.11.0 --------------89FC639615756AE2477DE3D6 Content-Type: text/plain Content-Disposition: inline Content-Transfer-Encoding: 8bit MIME-Version: 1.0 -- Sent via pgsql-hackers mailing list ([email protected]) To make changes to your subscription: http://www.postgresql.org/mailpref/pgsql-hackers --------------89FC639615756AE2477DE3D6-- ^ permalink raw reply [nested|flat] 53+ messages in thread
* [PATCH 4/4] Add a note about DROP NOT NULL and partitions @ 2017-02-10 06:03 amit <[email protected]> 0 siblings, 0 replies; 53+ messages in thread From: amit @ 2017-02-10 06:03 UTC (permalink / raw) On the ALTER TABLE refpage, it seems better to mention how to drop drop the not null constraint of a partition's column. Per suggestion from Corey Huinker. --- doc/src/sgml/ref/alter_table.sgml | 8 ++++++-- 1 file changed, 6 insertions(+), 2 deletions(-) diff --git a/doc/src/sgml/ref/alter_table.sgml b/doc/src/sgml/ref/alter_table.sgml index da431f8369..be857882bb 100644 --- a/doc/src/sgml/ref/alter_table.sgml +++ b/doc/src/sgml/ref/alter_table.sgml @@ -172,9 +172,13 @@ ALTER TABLE [ IF EXISTS ] <replaceable class="PARAMETER">name</replaceable> </para> <para> - If this table is a partition, one cannot perform <literal>DROP NOT NULL</> + If this table is a partition, one cannot perform <literal>DROP NOT NULL</literal> on a column if it is marked <literal>NOT NULL</literal> in the parent - table. + table. To drop the <literal>NOT NULL</literal> constraint from all the + partitions, perform <literal>DROP NOT NULL</literal> on the parent + table. One might however want to set it for only some partitions, + which is possible by doing <literal>SET NOT NULL</literal> on individual + partitions. </para> </listitem> </varlistentry> -- 2.11.0 --------------89FC639615756AE2477DE3D6 Content-Type: text/plain Content-Disposition: inline Content-Transfer-Encoding: 8bit MIME-Version: 1.0 -- Sent via pgsql-hackers mailing list ([email protected]) To make changes to your subscription: http://www.postgresql.org/mailpref/pgsql-hackers --------------89FC639615756AE2477DE3D6-- ^ permalink raw reply [nested|flat] 53+ messages in thread
* [PATCH 2/3] Add a note about DROP NOT NULL and partitions @ 2017-02-10 06:03 amit <[email protected]> 0 siblings, 0 replies; 53+ messages in thread From: amit @ 2017-02-10 06:03 UTC (permalink / raw) On the ALTER TABLE refpage, it seems better to mention how to drop drop the not null constraint of a partition's column. Per suggestion from Corey Huinker. --- doc/src/sgml/ref/alter_table.sgml | 8 ++++++-- 1 file changed, 6 insertions(+), 2 deletions(-) diff --git a/doc/src/sgml/ref/alter_table.sgml b/doc/src/sgml/ref/alter_table.sgml index da431f8369..be857882bb 100644 --- a/doc/src/sgml/ref/alter_table.sgml +++ b/doc/src/sgml/ref/alter_table.sgml @@ -172,9 +172,13 @@ ALTER TABLE [ IF EXISTS ] <replaceable class="PARAMETER">name</replaceable> </para> <para> - If this table is a partition, one cannot perform <literal>DROP NOT NULL</> + If this table is a partition, one cannot perform <literal>DROP NOT NULL</literal> on a column if it is marked <literal>NOT NULL</literal> in the parent - table. + table. To drop the <literal>NOT NULL</literal> constraint from all the + partitions, perform <literal>DROP NOT NULL</literal> on the parent + table. One might however want to set it for only some partitions, + which is possible by doing <literal>SET NOT NULL</literal> on individual + partitions. </para> </listitem> </varlistentry> -- 2.11.0 --------------434C61868FD2E7C005F82712 Content-Type: text/x-diff; name="0003-Listify-a-note-on-the-CREATE-TABLE-page.patch" Content-Transfer-Encoding: 7bit Content-Disposition: attachment; filename="0003-Listify-a-note-on-the-CREATE-TABLE-page.patch" ^ permalink raw reply [nested|flat] 53+ messages in thread
* [PATCH 4/4] Add a note about DROP NOT NULL and partitions @ 2017-02-10 06:03 amit <[email protected]> 0 siblings, 0 replies; 53+ messages in thread From: amit @ 2017-02-10 06:03 UTC (permalink / raw) On the ALTER TABLE refpage, it seems better to mention how to drop drop the not null constraint of a partition's column. Per suggestion from Corey Huinker. --- doc/src/sgml/ref/alter_table.sgml | 8 ++++++-- 1 file changed, 6 insertions(+), 2 deletions(-) diff --git a/doc/src/sgml/ref/alter_table.sgml b/doc/src/sgml/ref/alter_table.sgml index da431f8369..be857882bb 100644 --- a/doc/src/sgml/ref/alter_table.sgml +++ b/doc/src/sgml/ref/alter_table.sgml @@ -172,9 +172,13 @@ ALTER TABLE [ IF EXISTS ] <replaceable class="PARAMETER">name</replaceable> </para> <para> - If this table is a partition, one cannot perform <literal>DROP NOT NULL</> + If this table is a partition, one cannot perform <literal>DROP NOT NULL</literal> on a column if it is marked <literal>NOT NULL</literal> in the parent - table. + table. To drop the <literal>NOT NULL</literal> constraint from all the + partitions, perform <literal>DROP NOT NULL</literal> on the parent + table. One might however want to set it for only some partitions, + which is possible by doing <literal>SET NOT NULL</literal> on individual + partitions. </para> </listitem> </varlistentry> -- 2.11.0 --------------89FC639615756AE2477DE3D6 Content-Type: text/plain Content-Disposition: inline Content-Transfer-Encoding: 8bit MIME-Version: 1.0 -- Sent via pgsql-hackers mailing list ([email protected]) To make changes to your subscription: http://www.postgresql.org/mailpref/pgsql-hackers --------------89FC639615756AE2477DE3D6-- ^ permalink raw reply [nested|flat] 53+ messages in thread
* [PATCH 2/3] Add a note about DROP NOT NULL and partitions @ 2017-02-10 06:03 amit <[email protected]> 0 siblings, 0 replies; 53+ messages in thread From: amit @ 2017-02-10 06:03 UTC (permalink / raw) On the ALTER TABLE refpage, it seems better to mention how to drop drop the not null constraint of a partition's column. Per suggestion from Corey Huinker. --- doc/src/sgml/ref/alter_table.sgml | 8 ++++++-- 1 file changed, 6 insertions(+), 2 deletions(-) diff --git a/doc/src/sgml/ref/alter_table.sgml b/doc/src/sgml/ref/alter_table.sgml index da431f8369..be857882bb 100644 --- a/doc/src/sgml/ref/alter_table.sgml +++ b/doc/src/sgml/ref/alter_table.sgml @@ -172,9 +172,13 @@ ALTER TABLE [ IF EXISTS ] <replaceable class="PARAMETER">name</replaceable> </para> <para> - If this table is a partition, one cannot perform <literal>DROP NOT NULL</> + If this table is a partition, one cannot perform <literal>DROP NOT NULL</literal> on a column if it is marked <literal>NOT NULL</literal> in the parent - table. + table. To drop the <literal>NOT NULL</literal> constraint from all the + partitions, perform <literal>DROP NOT NULL</literal> on the parent + table. One might however want to set it for only some partitions, + which is possible by doing <literal>SET NOT NULL</literal> on individual + partitions. </para> </listitem> </varlistentry> -- 2.11.0 --------------434C61868FD2E7C005F82712 Content-Type: text/x-diff; name="0003-Listify-a-note-on-the-CREATE-TABLE-page.patch" Content-Transfer-Encoding: 7bit Content-Disposition: attachment; filename="0003-Listify-a-note-on-the-CREATE-TABLE-page.patch" ^ permalink raw reply [nested|flat] 53+ messages in thread
* [PATCH 2/3] Add a note about DROP NOT NULL and partitions @ 2017-02-10 06:03 amit <[email protected]> 0 siblings, 0 replies; 53+ messages in thread From: amit @ 2017-02-10 06:03 UTC (permalink / raw) On the ALTER TABLE refpage, it seems better to mention how to drop drop the not null constraint of a partition's column. Per suggestion from Corey Huinker. --- doc/src/sgml/ref/alter_table.sgml | 9 +++++++-- 1 file changed, 7 insertions(+), 2 deletions(-) diff --git a/doc/src/sgml/ref/alter_table.sgml b/doc/src/sgml/ref/alter_table.sgml index 077c00373d..b6be3a0dcb 100644 --- a/doc/src/sgml/ref/alter_table.sgml +++ b/doc/src/sgml/ref/alter_table.sgml @@ -172,9 +172,14 @@ ALTER TABLE [ IF EXISTS ] <replaceable class="PARAMETER">name</replaceable> </para> <para> - If this table is a partition, one cannot perform <literal>DROP NOT NULL</> + If this table is a partition, one cannot perform <literal>DROP NOT NULL</literal> on a column if it is marked <literal>NOT NULL</literal> in the parent - table. + table. To drop the <literal>NOT NULL</literal> constraint from all the + partitions, perform <literal>DROP NOT NULL</literal> on the parent + table. Even if there is no <literal>NOT NULL</> constraint on the + parent, such a constraint can still be added to individual partitions, + if desired; that is, the children can disallow nulls even if the parent + allows them, but not the other way around. </para> </listitem> </varlistentry> -- 2.11.0 --------------19C79A137EF2D0DB3BE72F79 Content-Type: text/x-diff; name="0003-Listify-a-note-on-the-CREATE-TABLE-page.patch" Content-Transfer-Encoding: 7bit Content-Disposition: attachment; filename="0003-Listify-a-note-on-the-CREATE-TABLE-page.patch" ^ permalink raw reply [nested|flat] 53+ messages in thread
* [PATCH 2/3] Add a note about DROP NOT NULL and partitions @ 2017-02-10 06:03 amit <[email protected]> 0 siblings, 0 replies; 53+ messages in thread From: amit @ 2017-02-10 06:03 UTC (permalink / raw) On the ALTER TABLE refpage, it seems better to mention how to drop drop the not null constraint of a partition's column. Per suggestion from Corey Huinker. --- doc/src/sgml/ref/alter_table.sgml | 9 +++++++-- 1 file changed, 7 insertions(+), 2 deletions(-) diff --git a/doc/src/sgml/ref/alter_table.sgml b/doc/src/sgml/ref/alter_table.sgml index 077c00373d..b6be3a0dcb 100644 --- a/doc/src/sgml/ref/alter_table.sgml +++ b/doc/src/sgml/ref/alter_table.sgml @@ -172,9 +172,14 @@ ALTER TABLE [ IF EXISTS ] <replaceable class="PARAMETER">name</replaceable> </para> <para> - If this table is a partition, one cannot perform <literal>DROP NOT NULL</> + If this table is a partition, one cannot perform <literal>DROP NOT NULL</literal> on a column if it is marked <literal>NOT NULL</literal> in the parent - table. + table. To drop the <literal>NOT NULL</literal> constraint from all the + partitions, perform <literal>DROP NOT NULL</literal> on the parent + table. Even if there is no <literal>NOT NULL</> constraint on the + parent, such a constraint can still be added to individual partitions, + if desired; that is, the children can disallow nulls even if the parent + allows them, but not the other way around. </para> </listitem> </varlistentry> -- 2.11.0 --------------19C79A137EF2D0DB3BE72F79 Content-Type: text/x-diff; name="0003-Listify-a-note-on-the-CREATE-TABLE-page.patch" Content-Transfer-Encoding: 7bit Content-Disposition: attachment; filename="0003-Listify-a-note-on-the-CREATE-TABLE-page.patch" ^ permalink raw reply [nested|flat] 53+ messages in thread
* [PATCH 4/4] Add a note about DROP NOT NULL and partitions @ 2017-02-10 06:03 amit <[email protected]> 0 siblings, 0 replies; 53+ messages in thread From: amit @ 2017-02-10 06:03 UTC (permalink / raw) On the ALTER TABLE refpage, it seems better to mention how to drop drop the not null constraint of a partition's column. Per suggestion from Corey Huinker. --- doc/src/sgml/ref/alter_table.sgml | 8 ++++++-- 1 file changed, 6 insertions(+), 2 deletions(-) diff --git a/doc/src/sgml/ref/alter_table.sgml b/doc/src/sgml/ref/alter_table.sgml index da431f8369..be857882bb 100644 --- a/doc/src/sgml/ref/alter_table.sgml +++ b/doc/src/sgml/ref/alter_table.sgml @@ -172,9 +172,13 @@ ALTER TABLE [ IF EXISTS ] <replaceable class="PARAMETER">name</replaceable> </para> <para> - If this table is a partition, one cannot perform <literal>DROP NOT NULL</> + If this table is a partition, one cannot perform <literal>DROP NOT NULL</literal> on a column if it is marked <literal>NOT NULL</literal> in the parent - table. + table. To drop the <literal>NOT NULL</literal> constraint from all the + partitions, perform <literal>DROP NOT NULL</literal> on the parent + table. One might however want to set it for only some partitions, + which is possible by doing <literal>SET NOT NULL</literal> on individual + partitions. </para> </listitem> </varlistentry> -- 2.11.0 --------------89FC639615756AE2477DE3D6 Content-Type: text/plain Content-Disposition: inline Content-Transfer-Encoding: 8bit MIME-Version: 1.0 -- Sent via pgsql-hackers mailing list ([email protected]) To make changes to your subscription: http://www.postgresql.org/mailpref/pgsql-hackers --------------89FC639615756AE2477DE3D6-- ^ permalink raw reply [nested|flat] 53+ messages in thread
* [PATCH 2/3] Add a note about DROP NOT NULL and partitions @ 2017-02-10 06:03 amit <[email protected]> 0 siblings, 0 replies; 53+ messages in thread From: amit @ 2017-02-10 06:03 UTC (permalink / raw) On the ALTER TABLE refpage, it seems better to mention how to drop drop the not null constraint of a partition's column. Per suggestion from Corey Huinker. --- doc/src/sgml/ref/alter_table.sgml | 8 ++++++-- 1 file changed, 6 insertions(+), 2 deletions(-) diff --git a/doc/src/sgml/ref/alter_table.sgml b/doc/src/sgml/ref/alter_table.sgml index da431f8369..be857882bb 100644 --- a/doc/src/sgml/ref/alter_table.sgml +++ b/doc/src/sgml/ref/alter_table.sgml @@ -172,9 +172,13 @@ ALTER TABLE [ IF EXISTS ] <replaceable class="PARAMETER">name</replaceable> </para> <para> - If this table is a partition, one cannot perform <literal>DROP NOT NULL</> + If this table is a partition, one cannot perform <literal>DROP NOT NULL</literal> on a column if it is marked <literal>NOT NULL</literal> in the parent - table. + table. To drop the <literal>NOT NULL</literal> constraint from all the + partitions, perform <literal>DROP NOT NULL</literal> on the parent + table. One might however want to set it for only some partitions, + which is possible by doing <literal>SET NOT NULL</literal> on individual + partitions. </para> </listitem> </varlistentry> -- 2.11.0 --------------434C61868FD2E7C005F82712 Content-Type: text/x-diff; name="0003-Listify-a-note-on-the-CREATE-TABLE-page.patch" Content-Transfer-Encoding: 7bit Content-Disposition: attachment; filename="0003-Listify-a-note-on-the-CREATE-TABLE-page.patch" ^ permalink raw reply [nested|flat] 53+ messages in thread
* [PATCH 2/3] Add a note about DROP NOT NULL and partitions @ 2017-02-10 06:03 amit <[email protected]> 0 siblings, 0 replies; 53+ messages in thread From: amit @ 2017-02-10 06:03 UTC (permalink / raw) On the ALTER TABLE refpage, it seems better to mention how to drop drop the not null constraint of a partition's column. Per suggestion from Corey Huinker. --- doc/src/sgml/ref/alter_table.sgml | 9 +++++++-- 1 file changed, 7 insertions(+), 2 deletions(-) diff --git a/doc/src/sgml/ref/alter_table.sgml b/doc/src/sgml/ref/alter_table.sgml index 077c00373d..b6be3a0dcb 100644 --- a/doc/src/sgml/ref/alter_table.sgml +++ b/doc/src/sgml/ref/alter_table.sgml @@ -172,9 +172,14 @@ ALTER TABLE [ IF EXISTS ] <replaceable class="PARAMETER">name</replaceable> </para> <para> - If this table is a partition, one cannot perform <literal>DROP NOT NULL</> + If this table is a partition, one cannot perform <literal>DROP NOT NULL</literal> on a column if it is marked <literal>NOT NULL</literal> in the parent - table. + table. To drop the <literal>NOT NULL</literal> constraint from all the + partitions, perform <literal>DROP NOT NULL</literal> on the parent + table. Even if there is no <literal>NOT NULL</> constraint on the + parent, such a constraint can still be added to individual partitions, + if desired; that is, the children can disallow nulls even if the parent + allows them, but not the other way around. </para> </listitem> </varlistentry> -- 2.11.0 --------------19C79A137EF2D0DB3BE72F79 Content-Type: text/x-diff; name="0003-Listify-a-note-on-the-CREATE-TABLE-page.patch" Content-Transfer-Encoding: 7bit Content-Disposition: attachment; filename="0003-Listify-a-note-on-the-CREATE-TABLE-page.patch" ^ permalink raw reply [nested|flat] 53+ messages in thread
* [PATCH 2/3] Add a note about DROP NOT NULL and partitions @ 2017-02-10 06:03 amit <[email protected]> 0 siblings, 0 replies; 53+ messages in thread From: amit @ 2017-02-10 06:03 UTC (permalink / raw) On the ALTER TABLE refpage, it seems better to mention how to drop drop the not null constraint of a partition's column. Per suggestion from Corey Huinker. --- doc/src/sgml/ref/alter_table.sgml | 9 +++++++-- 1 file changed, 7 insertions(+), 2 deletions(-) diff --git a/doc/src/sgml/ref/alter_table.sgml b/doc/src/sgml/ref/alter_table.sgml index 077c00373d..b6be3a0dcb 100644 --- a/doc/src/sgml/ref/alter_table.sgml +++ b/doc/src/sgml/ref/alter_table.sgml @@ -172,9 +172,14 @@ ALTER TABLE [ IF EXISTS ] <replaceable class="PARAMETER">name</replaceable> </para> <para> - If this table is a partition, one cannot perform <literal>DROP NOT NULL</> + If this table is a partition, one cannot perform <literal>DROP NOT NULL</literal> on a column if it is marked <literal>NOT NULL</literal> in the parent - table. + table. To drop the <literal>NOT NULL</literal> constraint from all the + partitions, perform <literal>DROP NOT NULL</literal> on the parent + table. Even if there is no <literal>NOT NULL</> constraint on the + parent, such a constraint can still be added to individual partitions, + if desired; that is, the children can disallow nulls even if the parent + allows them, but not the other way around. </para> </listitem> </varlistentry> -- 2.11.0 --------------19C79A137EF2D0DB3BE72F79 Content-Type: text/x-diff; name="0003-Listify-a-note-on-the-CREATE-TABLE-page.patch" Content-Transfer-Encoding: 7bit Content-Disposition: attachment; filename="0003-Listify-a-note-on-the-CREATE-TABLE-page.patch" ^ permalink raw reply [nested|flat] 53+ messages in thread
* [PATCH] Do not push the active snapshot for copy_table_data before it's needed. @ 2026-04-10 10:17 Antonin Houska <[email protected]> 0 siblings, 0 replies; 53+ messages in thread From: Antonin Houska @ 2026-04-10 10:17 UTC (permalink / raw) make_new_heap() can launch parallel workers when building index on TOAST relation. If the snapshot for copy_table_data() is already the active snapshot, the workers can incorrectly consider it their transaction snapshot. --- src/backend/commands/repack.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/src/backend/commands/repack.c b/src/backend/commands/repack.c index 58e3867246f..08fd132a4e3 100644 --- a/src/backend/commands/repack.c +++ b/src/backend/commands/repack.c @@ -1013,8 +1013,6 @@ rebuild_relation(Relation OldHeap, Relation index, bool verbose, * Wait until the worker has the initial snapshot and retrieve it. */ snapshot = get_initial_snapshot(decoding_worker); - - PushActiveSnapshot(snapshot); } /* for CLUSTER or REPACK USING INDEX, mark the index as the one to use */ @@ -1038,6 +1036,8 @@ rebuild_relation(Relation OldHeap, Relation index, bool verbose, NewHeap = table_open(OIDNewHeap, NoLock); /* Copy the heap data into the new table in the desired order */ + if (snapshot) + PushActiveSnapshot(snapshot); copy_table_data(NewHeap, OldHeap, index, snapshot, verbose, &swap_toast_by_content, &frozenXid, &cutoffMulti); -- 2.47.3 --=-=-=-- ^ permalink raw reply [nested|flat] 53+ messages in thread
end of thread, other threads:[~2026-04-10 10:17 UTC | newest] Thread overview: 53+ messages (download: mbox mbox.gz follow: Atom feed) -- links below jump to the message on this page -- 2017-02-10 06:03 [PATCH 2/3] Add a note about DROP NOT NULL and partitions amit <[email protected]> 2017-02-10 06:03 [PATCH 2/3] Add a note about DROP NOT NULL and partitions amit <[email protected]> 2017-02-10 06:03 [PATCH 2/3] Add a note about DROP NOT NULL and partitions amit <[email protected]> 2017-02-10 06:03 [PATCH 2/3] Add a note about DROP NOT NULL and partitions amit <[email protected]> 2017-02-10 06:03 [PATCH 4/4] Add a note about DROP NOT NULL and partitions amit <[email protected]> 2017-02-10 06:03 [PATCH 2/3] Add a note about DROP NOT NULL and partitions amit <[email protected]> 2017-02-10 06:03 [PATCH 2/3] Add a note about DROP NOT NULL and partitions amit <[email protected]> 2017-02-10 06:03 [PATCH 4/4] Add a note about DROP NOT NULL and partitions amit <[email protected]> 2017-02-10 06:03 [PATCH 2/3] Add a note about DROP NOT NULL and partitions amit <[email protected]> 2017-02-10 06:03 [PATCH 2/3] Add a note about DROP NOT NULL and partitions amit <[email protected]> 2017-02-10 06:03 [PATCH 4/4] Add a note about DROP NOT NULL and partitions amit <[email protected]> 2017-02-10 06:03 [PATCH 4/4] Add a note about DROP NOT NULL and partitions amit <[email protected]> 2017-02-10 06:03 [PATCH 4/4] Add a note about DROP NOT NULL and partitions amit <[email protected]> 2017-02-10 06:03 [PATCH 4/4] Add a note about DROP NOT NULL and partitions amit <[email protected]> 2017-02-10 06:03 [PATCH 4/4] Add a note about DROP NOT NULL and partitions amit <[email protected]> 2017-02-10 06:03 [PATCH 4/4] Add a note about DROP NOT NULL and partitions amit <[email protected]> 2017-02-10 06:03 [PATCH 2/3] Add a note about DROP NOT NULL and partitions amit <[email protected]> 2017-02-10 06:03 [PATCH 2/3] Add a note about DROP NOT NULL and partitions amit <[email protected]> 2017-02-10 06:03 [PATCH 2/3] Add a note about DROP NOT NULL and partitions amit <[email protected]> 2017-02-10 06:03 [PATCH 2/3] Add a note about DROP NOT NULL and partitions amit <[email protected]> 2017-02-10 06:03 [PATCH 2/3] Add a note about DROP NOT NULL and partitions amit <[email protected]> 2017-02-10 06:03 [PATCH 4/4] Add a note about DROP NOT NULL and partitions amit <[email protected]> 2017-02-10 06:03 [PATCH 2/3] Add a note about DROP NOT NULL and partitions amit <[email protected]> 2017-02-10 06:03 [PATCH 2/3] Add a note about DROP NOT NULL and partitions amit <[email protected]> 2017-02-10 06:03 [PATCH 4/4] Add a note about DROP NOT NULL and partitions amit <[email protected]> 2017-02-10 06:03 [PATCH 4/4] Add a note about DROP NOT NULL and partitions amit <[email protected]> 2017-02-10 06:03 [PATCH 2/3] Add a note about DROP NOT NULL and partitions amit <[email protected]> 2017-02-10 06:03 [PATCH 2/3] Add a note about DROP NOT NULL and partitions amit <[email protected]> 2017-02-10 06:03 [PATCH 2/3] Add a note about DROP NOT NULL and partitions amit <[email protected]> 2017-02-10 06:03 [PATCH 2/3] Add a note about DROP NOT NULL and partitions amit <[email protected]> 2017-02-10 06:03 [PATCH 2/3] Add a note about DROP NOT NULL and partitions amit <[email protected]> 2017-02-10 06:03 [PATCH 2/3] Add a note about DROP NOT NULL and partitions amit <[email protected]> 2017-02-10 06:03 [PATCH 4/4] Add a note about DROP NOT NULL and partitions amit <[email protected]> 2017-02-10 06:03 [PATCH 2/3] Add a note about DROP NOT NULL and partitions amit <[email protected]> 2017-02-10 06:03 [PATCH 2/3] Add a note about DROP NOT NULL and partitions amit <[email protected]> 2017-02-10 06:03 [PATCH 2/3] Add a note about DROP NOT NULL and partitions amit <[email protected]> 2017-02-10 06:03 [PATCH 2/3] Add a note about DROP NOT NULL and partitions amit <[email protected]> 2017-02-10 06:03 [PATCH 4/4] Add a note about DROP NOT NULL and partitions amit <[email protected]> 2017-02-10 06:03 [PATCH 2/3] Add a note about DROP NOT NULL and partitions amit <[email protected]> 2017-02-10 06:03 [PATCH 4/4] Add a note about DROP NOT NULL and partitions amit <[email protected]> 2017-02-10 06:03 [PATCH 2/3] Add a note about DROP NOT NULL and partitions amit <[email protected]> 2017-02-10 06:03 [PATCH 4/4] Add a note about DROP NOT NULL and partitions amit <[email protected]> 2017-02-10 06:03 [PATCH 4/4] Add a note about DROP NOT NULL and partitions amit <[email protected]> 2017-02-10 06:03 [PATCH 2/3] Add a note about DROP NOT NULL and partitions amit <[email protected]> 2017-02-10 06:03 [PATCH 4/4] Add a note about DROP NOT NULL and partitions amit <[email protected]> 2017-02-10 06:03 [PATCH 2/3] Add a note about DROP NOT NULL and partitions amit <[email protected]> 2017-02-10 06:03 [PATCH 2/3] Add a note about DROP NOT NULL and partitions amit <[email protected]> 2017-02-10 06:03 [PATCH 2/3] Add a note about DROP NOT NULL and partitions amit <[email protected]> 2017-02-10 06:03 [PATCH 4/4] Add a note about DROP NOT NULL and partitions amit <[email protected]> 2017-02-10 06:03 [PATCH 2/3] Add a note about DROP NOT NULL and partitions amit <[email protected]> 2017-02-10 06:03 [PATCH 2/3] Add a note about DROP NOT NULL and partitions amit <[email protected]> 2017-02-10 06:03 [PATCH 2/3] Add a note about DROP NOT NULL and partitions amit <[email protected]> 2026-04-10 10:17 [PATCH] Do not push the active snapshot for copy_table_data before it's needed. Antonin Houska <[email protected]>
This inbox is served by agora; see mirroring instructions for how to clone and mirror all data and code used for this inbox