Received: from malur.postgresql.org ([217.196.149.56]) by arkaria.postgresql.org with esmtp (Exim 4.84_2) (envelope-from ) id 1dwUSY-00048R-Q6 for pgsql-hackers@arkaria.postgresql.org; Mon, 25 Sep 2017 14:34:10 +0000 Received: from localhost ([127.0.0.1] helo=postgresql.org) by malur.postgresql.org with smtp (Exim 4.84_2) (envelope-from ) id 1dwUSY-0003Zd-3p for pgsql-hackers@arkaria.postgresql.org; Mon, 25 Sep 2017 14:34:10 +0000 Received: from makus.postgresql.org ([2001:4800:1501:1::229]) by malur.postgresql.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_CBC_SHA384:256) (Exim 4.84_2) (envelope-from ) id 1dwUR0-0000qN-85 for pgsql-hackers@postgresql.org; Mon, 25 Sep 2017 14:32:34 +0000 Received: from sss.pgh.pa.us ([66.207.139.130]) by makus.postgresql.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_CBC_SHA384:256) (Exim 4.84_2) (envelope-from ) id 1dwUQx-00017o-Gu for pgsql-hackers@postgresql.org; Mon, 25 Sep 2017 14:32:32 +0000 Received: from sss1.sss.pgh.pa.us (localhost [127.0.0.1]) by sss.pgh.pa.us (8.14.4/8.14.4) with ESMTP id v8PEWP20026671; Mon, 25 Sep 2017 10:32:27 -0400 From: Tom Lane To: Amit Langote cc: Michael Paquier , PostgreSQL mailing lists Subject: Re: Shaky coding for vacuuming partitioned relations In-reply-to: References: <25023.1506107590@sss.pgh.pa.us> Comments: In-reply-to Amit Langote message dated "Mon, 25 Sep 2017 16:42:22 +0900" MIME-Version: 1.0 Content-Type: text/plain; charset="us-ascii" Content-ID: <26669.1506349945.1@sss.pgh.pa.us> Date: Mon, 25 Sep 2017 10:32:25 -0400 Message-ID: <26670.1506349945@sss.pgh.pa.us> List-Archive: List-Help: List-ID: List-Owner: List-Post: List-Subscribe: List-Unsubscribe: X-Mailing-List: pgsql-hackers Precedence: bulk Sender: pgsql-hackers-owner@postgresql.org Amit Langote writes: > On 2017/09/25 12:10, Michael Paquier wrote: >> As long as I don't forget... Another thing currently on HEAD and >> REL_10_STABLE is that OIDs of partitioned tables are used, but the >> RangeVar of the parent is used for error reports. This leads to >> incorrect reports if a partition gets away in the middle of autovacuum >> as only information about the parent is reported to the user. > Oh, you're right. The original RangeVar (corresponding to the table > mentioned in the command) refers to the parent table. Yeah, I'd noticed that while reviewing the vacuum-multiple-tables patch. My thought about fixing it was to pass a null RangeVar when handling a table we'd identified through inheritance or pg_class-scanning, to indicate that this wasn't a table named in the original command. This only works conveniently if you decide that it's appropriate to silently ignore relation_open failure on such table OIDs, but I think it is. Not sure about whether we ought to try to fix that in v10. It's a mostly-cosmetic problem in what ought to be an infrequent corner case, so it might not be worth taking risks for post-RC1. OTOH, I would not be surprised to get bug reports about it down the road. regards, tom lane -- Sent via pgsql-hackers mailing list (pgsql-hackers@postgresql.org) To make changes to your subscription: http://www.postgresql.org/mailpref/pgsql-hackers