Received: from malur.postgresql.org ([217.196.149.56]) by arkaria.postgresql.org with esmtps (TLS1.3:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.92) (envelope-from ) id 1pNaxC-0007AI-RG for pgsql-hackers@arkaria.postgresql.org; Thu, 02 Feb 2023 14:52:46 +0000 Received: from localhost ([127.0.0.1] helo=malur.postgresql.org) by malur.postgresql.org with esmtp (Exim 4.92) (envelope-from ) id 1pNaxB-00053U-Oq for pgsql-hackers@arkaria.postgresql.org; Thu, 02 Feb 2023 14:52:45 +0000 Received: from magus.postgresql.org ([2a02:c0:301:0:ffff::29]) by malur.postgresql.org with esmtps (TLS1.3:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.92) (envelope-from ) id 1pNaxB-00053F-Fm for pgsql-hackers@lists.postgresql.org; Thu, 02 Feb 2023 14:52:45 +0000 Received: from sss.pgh.pa.us ([66.207.139.130]) by magus.postgresql.org with esmtps (TLS1.3:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.92) (envelope-from ) id 1pNax9-00070p-2t for pgsql-hackers@lists.postgresql.org; Thu, 02 Feb 2023 14:52:45 +0000 Received: from sss1.sss.pgh.pa.us (localhost [127.0.0.1]) by sss.pgh.pa.us (8.15.2/8.15.2) with ESMTP id 312EqYXp1533087; Thu, 2 Feb 2023 09:52:34 -0500 From: Tom Lane To: Andrew Dunstan cc: David Rowley , Peter Geoghegan , Robert Haas , pgsql-hackers@lists.postgresql.org, Andrew Subject: Re: pg_dump versus hash partitioning In-reply-to: References: <1376149.1675268279@sss.pgh.pa.us> <1412538.1675283692@sss.pgh.pa.us> <1425446.1675291093@sss.pgh.pa.us> <1440373.1675299790@sss.pgh.pa.us> Comments: In-reply-to Andrew Dunstan message dated "Thu, 02 Feb 2023 07:56:22 -0500" MIME-Version: 1.0 Content-Type: text/plain; charset="us-ascii" Content-ID: <1533085.1675349554.1@sss.pgh.pa.us> Date: Thu, 02 Feb 2023 09:52:34 -0500 Message-ID: <1533086.1675349554@sss.pgh.pa.us> List-Id: List-Help: List-Subscribe: List-Post: List-Owner: List-Archive: Archived-At: Precedence: bulk Andrew Dunstan writes: > On 2023-02-01 We 20:03, Tom Lane wrote: >> Anyway, after re-reading the old thread I wonder if my first instinct >> (force --load-via-partition-root for enum hash cases only) was the >> best compromise after all. I'm not sure how painful it is to get >> pg_dump to detect such cases, but it's probably possible. > Given the other problems you enumerated upthread, I'd be more inclined > to go with your other suggestion of > "--load-via-partition-root=on/off/auto" (with the default presumably > "auto"). Hmm ... is there any actual value in "off" in this case? We can be just about certain that dump/reload of a hashed enum key will fail. If we made "auto" also use --load-via-partition-root for range keys having collation properties, there'd be more of an argument for letting users override it. regards, tom lane