Received: from malur.postgresql.org ([217.196.149.56]) by arkaria.postgresql.org with esmtp (Exim 4.84_2) (envelope-from ) id 1bN0D3-0006Wv-Qr for pgsql-bugs@arkaria.postgresql.org; Tue, 12 Jul 2016 16:06:57 +0000 Received: from localhost ([127.0.0.1] helo=postgresql.org) by malur.postgresql.org with smtp (Exim 4.84_2) (envelope-from ) id 1bN0D3-0005xJ-EA for pgsql-bugs@arkaria.postgresql.org; Tue, 12 Jul 2016 16:06:57 +0000 Received: from magus.postgresql.org ([2a02:c0:301:0:ffff::29]) by malur.postgresql.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_CBC_SHA384:256) (Exim 4.84_2) (envelope-from ) id 1bN0CP-0005Db-No for pgsql-bugs@postgresql.org; Tue, 12 Jul 2016 16:06:17 +0000 Received: from sss.pgh.pa.us ([66.207.139.130]) by magus.postgresql.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_CBC_SHA384:256) (Exim 4.84_2) (envelope-from ) id 1bN0CM-0005J5-Av for pgsql-bugs@postgresql.org; Tue, 12 Jul 2016 16:06:17 +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 u6CG6Ctp024493; Tue, 12 Jul 2016 12:06:12 -0400 From: Tom Lane To: Mike Porter cc: pgsql-bugs@postgresql.org Subject: Re: grouping treated as keyword in function return table In-reply-to: References: Comments: In-reply-to Mike Porter message dated "Tue, 12 Jul 2016 11:51:05 -0400" Date: Tue, 12 Jul 2016 12:06:12 -0400 Message-ID: <24492.1468339572@sss.pgh.pa.us> X-Pg-Spam-Score: -3.2 (---) List-Archive: List-Help: List-ID: List-Owner: List-Post: List-Subscribe: List-Unsubscribe: X-Mailing-List: pgsql-bugs Precedence: bulk Sender: pgsql-bugs-owner@postgresql.org Mike Porter writes: > Postgres 9.5.3 built from source. However, I think this has been > happening for a long time. Only since 9.5, because GROUPING wasn't a keyword before that. > So, in almost all cases grouping is not required to be quoted, > however when used in a table defined as a function return type, it > is. This is expected given that it's now partially reserved. > Additionally, pg_dumpall does not quote grouping when dumping > the function so the function will not be restored when the dump is > loaded. That would be a pg_dump bug, but it doesn't happen for me: I get CREATE FUNCTION a() RETURNS TABLE("grouping" integer) LANGUAGE sql AS $$ select 1; $$; Sure you're using 9.5 pg_dump? regards, tom lane -- Sent via pgsql-bugs mailing list (pgsql-bugs@postgresql.org) To make changes to your subscription: http://www.postgresql.org/mailpref/pgsql-bugs