Received: from malur.postgresql.org ([217.196.149.56]) by arkaria.postgresql.org with esmtps (TLS1.3) tls TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384 (Exim 4.94.2) (envelope-from ) id 1snYKI-004Nox-8L for pgsql-hackers@arkaria.postgresql.org; Mon, 09 Sep 2024 06:56:43 +0000 Received: from localhost ([127.0.0.1] helo=malur.postgresql.org) by malur.postgresql.org with esmtp (Exim 4.94.2) (envelope-from ) id 1snYKH-007O8O-Ch for pgsql-hackers@arkaria.postgresql.org; Mon, 09 Sep 2024 06:56:41 +0000 Received: from makus.postgresql.org ([2001:4800:3e1:1::229]) by malur.postgresql.org with esmtps (TLS1.3) tls TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384 (Exim 4.94.2) (envelope-from ) id 1snYKG-007O8F-J3 for pgsql-hackers@lists.postgresql.org; Mon, 09 Sep 2024 06:56:41 +0000 Received: from fout3-smtp.messagingengine.com ([103.168.172.146]) by makus.postgresql.org with esmtps (TLS1.3) tls TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384 (Exim 4.94.2) (envelope-from ) id 1snYKD-000G36-Iv for pgsql-hackers@lists.postgresql.org; Mon, 09 Sep 2024 06:56:39 +0000 Received: from phl-compute-06.internal (phl-compute-06.phl.internal [10.202.2.46]) by mailfout.phl.internal (Postfix) with ESMTP id 8F99E138026A; Mon, 9 Sep 2024 02:56:36 -0400 (EDT) Received: from phl-mailfrontend-01 ([10.202.2.162]) by phl-compute-06.internal (MEProxy); Mon, 09 Sep 2024 02:56:36 -0400 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=paquier.xyz; h= cc:cc:content-type:content-type:date:date:from:from:in-reply-to :in-reply-to:message-id:mime-version:references:reply-to:subject :subject:to:to; s=fm1; t=1725864996; x=1725951396; bh=Qm3apaZq06 WnyOBDlDhD88RG5/tH4lwfdCAa5nMLoDk=; b=n5bEKp6a1VBNvibbdGlK2IkS7p p1Z71adgi9dUytx8hyKqjPbLT6v9c+E96m+CuNkLs3ea0QJGZBeWG87DHD/RosqX HphgNAOQpol3apWvfhnYpyDyfpczKZqkRmId7N+X8iTh5aXfeuPOttFuph7c9XkG hHoso39UN/J6uFBpwE2yhIY4T18NBrXcHB57z3Cltt56sOj6b2k0sfqx2AwIX6Nb oIPYZXkDtaJ5JJvRNOEpxbBOm7smplLvXUmYUBubRGhDMmz1PiIP7au3734G+r24 ovxDklO0/pYQ+shN2wy7KLyJ9zAO3mkO7elZSkhdfSinZ5hp9FMH1SAKGu9g== DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d= messagingengine.com; h=cc:cc:content-type:content-type:date:date :feedback-id:feedback-id:from:from:in-reply-to:in-reply-to :message-id:mime-version:references:reply-to:subject:subject:to :to:x-me-proxy:x-me-proxy:x-me-sender:x-me-sender:x-sasl-enc; s= fm1; t=1725864996; x=1725951396; bh=Qm3apaZq06WnyOBDlDhD88RG5/tH 4lwfdCAa5nMLoDk=; b=BKhCX699BndFzbS9IcsExsmm0gp80uZ0YA3ZfY9YWfJu l7oDjyje/G4rRhba2w4CfeeiqGM7kRbqHYu3cj/s/qPFgmIvBO6A9mXUq0Ppmte9 b4SMFq4X7CKWQL0uDq5jDX64NDxMVPgjM4OE2GhXd6yuCyhJW2YKR9mOGE3raIia vkPwvwkOjXPOtwbxCnhHF96fsytRmcvGCyrn/rGHVi+aIWVkKZig/Ll4Hnmo3bdt DsWWKBBNQZ95AaeZg3nQxrs9h4pYDliQdR5ZlEUn8RCoDiU/bb3lbCs/hyIJbxoW jCxiwkVKqAWRjnE8RAobigLXNwF+2B+BMRN6VSfmXw== X-ME-Sender: X-ME-Received: X-ME-Proxy-Cause: gggruggvucftvghtrhhoucdtuddrgeeftddrudeiiedgkeeiucetufdoteggodetrfdotf fvucfrrhhofhhilhgvmecuhfgrshhtofgrihhlpdggtfgfnhhsuhgsshgtrhhisggvpdfu rfetoffkrfgpnffqhgenuceurghilhhouhhtmecufedttdenucesvcftvggtihhpihgvnh htshculddquddttddmnegfrhhlucfvnfffucdljedtmdenucfjughrpeffhffvvefukfhf gggtuggjsehgtderredttddvnecuhfhrohhmpefoihgthhgrvghlucfrrghquhhivghruc eomhhitghhrggvlhesphgrqhhuihgvrhdrgiihiieqnecuggftrfgrthhtvghrnhepteel ieefudffhffhtdetleeggeegfffhkeeuveetiefgudduvedutefggeeivdejnecuvehluh hsthgvrhfuihiivgeptdenucfrrghrrghmpehmrghilhhfrhhomhepmhhitghhrggvlhes phgrqhhuihgvrhdrgiihiidpnhgspghrtghpthhtohepfedpmhhouggvpehsmhhtphhouh htpdhrtghpthhtohepnhgrthhhrghnuggsohhsshgrrhhtsehgmhgrihhlrdgtohhmpdhr tghpthhtohepuggrvhhiugdrghdrjhhohhhnshhtohhnsehgmhgrihhlrdgtohhmpdhrtg hpthhtohepphhgshhqlhdqhhgrtghkvghrsheslhhishhtshdrphhoshhtghhrvghsqhhl rdhorhhg X-ME-Proxy: Feedback-ID: i0fe9450f:Fastmail Received: by mail.messagingengine.com (Postfix) with ESMTPA; Mon, 9 Sep 2024 02:56:33 -0400 (EDT) Date: Mon, 9 Sep 2024 15:56:14 +0900 From: Michael Paquier To: Nathan Bossart Cc: "David G. Johnston" , Postgres hackers Subject: Re: Partitioned tables and [un]loggedness Message-ID: References: MIME-Version: 1.0 Content-Type: multipart/signed; micalg=pgp-sha512; protocol="application/pgp-signature"; boundary="DDWizPu1dfRpPx1Y" Content-Disposition: inline In-Reply-To: List-Id: List-Help: List-Subscribe: List-Post: List-Owner: List-Archive: Archived-At: Precedence: bulk --DDWizPu1dfRpPx1Y Content-Type: text/plain; charset=us-ascii Content-Disposition: inline On Tue, Sep 03, 2024 at 10:33:02AM -0500, Nathan Bossart wrote: > This works correctly for CREATE TABLE, but ALTER TABLE still succeeds. > Interestingly, it doesn't seem to actually change relpersistence for > partitioned tables. I think we might need to adjust > ATPrepChangePersistence(). Adjusting ATPrepChangePersistence() looks incorrect to me seeing that we have all the machinery in ATSimplePermissions() at our disposal, and that this routine decides that ATT_TABLE should map to both RELKIND_RELATION and RELKIND_PARTITIONED_TABLE. How about inventing a new ATT_PARTITIONED_TABLE and make a clean split between both relkinds? I'd guess that blocking both SET LOGGED and UNLOGGED for partitioned tables is the best move, even if it is possible to block only one or the other, of course. -- Michael --DDWizPu1dfRpPx1Y Content-Type: application/pgp-signature; name="signature.asc" -----BEGIN PGP SIGNATURE----- iQIzBAABCgAdFiEEG72nH6vTowiyblFKnvQgOdbyQH0FAmbenA4ACgkQnvQgOdby QH2JPQ//eeHAQsrROjepI830pOjwzTIM/oNiIxOH2AlPjUqU6zW9QuEE4fceqclH 2GtZmXhdf7/ynZENE5TNqvqQ27JfoRyj9FftrGDbeY3BVw0h3+9eTZ34/cfiTzXf TWxyrHAdkH5w4gOqaLW5EXJsuMxeJPxFVgrBN9wKK5RU+8YkdHAh9zZovfVYaNN7 awcupLKzB4oX/8MIdWI/j1TDwkqIAIiX7Py9dXh+PlMpt6qcYF0kbosvQ21J+UdB 0HprsaM7/k4KOyzHdAwnaY3zeY53Z/ry6N9a4cylfNLBox/piKQevZaRYMR+Xoqi LiuQT6477uXx4spYdKuAX7XgYMVd+Ta9jAh0l5gxyOfhC5NUxlBl4SFKmNPvvL6u PfTEMmJaEzljfrhMvWPKEch4D1AfWRoT35+LklIXZfy2nRfX8Q7x++sNhiV02ATY spx8Ln8AO0jCXt/b7NBir4IQmR4bouVFeCGWpYKif1p0t3nTH5Il3eMlmVARS6Lu PgThNFtORoLkq1OLwqMS/lnozdqwI6uKlW+teWNSujjTNw8cBqOe63MbtEeY4Dt+ iXpNkM3tnkPWADT5lk43XAU2fqTKG9zQfJsRPiyCFqkvsxlBhbxbHuTimOOjcKdn TcPVC1Hfdndj6h2x7wS80GdK1Hvt7N8uPdsozbTscYovLFrNJ4Y= =k4QD -----END PGP SIGNATURE----- --DDWizPu1dfRpPx1Y--