From 3a787b95f5a35b53cd958855ec6fc4ff9fc9a455 Mon Sep 17 00:00:00 2001 From: Justin Pryzby Date: Thu, 11 Apr 2019 00:24:44 -0500 Subject: [PATCH v1 1/2] Reinstate warnings regarding large heirarchies Put back warnings regarding high planning time and/or RAM use for large inheritance heirarchies, and high planning time for large number of partitions not pruned during planning with declaratively partitioned tables. Discussion: /message-id/CAKJS1f8RW-mHQ8aEWD5Dv0%2B8A1wH5tHHdYMGW9y5sXqnE0X9wA%40mail.gmail.com https://commitfest.postgresql.org/23/2065/ Author: Robert Haas, David Rowley Reviewed by: Amit Langote, Justin Pryzby --- doc/src/sgml/ddl.sgml | 20 ++++++++++++++++++++ 1 file changed, 20 insertions(+) diff --git a/doc/src/sgml/ddl.sgml b/doc/src/sgml/ddl.sgml index 244d5ce..83cbc66 100644 --- a/doc/src/sgml/ddl.sgml +++ b/doc/src/sgml/ddl.sgml @@ -3582,6 +3582,26 @@ VALUES ('Albany', NULL, NULL, 'NY'); offer flexibility but do not have some of the performance benefits of built-in declarative partitioning. + + + + When using table inheritance, partition hierarchies with more than a few + hundred partitions are not recommended. Larger partition hierarchies may + incur long planning time, and, in the case of UPDATE + and DELETE, excessive memory usage. When inheritance + is used, see also the limitations described in + . + + + + When using declarative partitioning, the overhead of query planning + is directly related to the number of unpruned partitions. Planning is + generally fast with small numbers of unpruned partitions, even in + partition hierarchies containing many thousands of partitions. However, + long planning time will be incurred by large partition hierarchies if + partition pruning is not possible during the planning phase. + + -- 2.1.4