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 1jqjOH-0000f0-TW for pgsql-hackers@arkaria.postgresql.org; Wed, 01 Jul 2020 20:31:33 +0000 Received: from localhost ([127.0.0.1] helo=malur.postgresql.org) by malur.postgresql.org with esmtp (Exim 4.92) (envelope-from ) id 1jqjOG-0000nu-Oy for pgsql-hackers@arkaria.postgresql.org; Wed, 01 Jul 2020 20:31:32 +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 1jqjOG-0000nl-ID for pgsql-hackers@lists.postgresql.org; Wed, 01 Jul 2020 20:31:32 +0000 Received: from relay4-d.mail.gandi.net ([217.70.183.196]) by magus.postgresql.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.92) (envelope-from ) id 1jqjOE-0001W7-FP for pgsql-hackers@postgresql.org; Wed, 01 Jul 2020 20:31:32 +0000 X-Originating-IP: 93.10.30.82 Received: from [172.16.255.146] (82.30.10.93.rev.sfr.net [93.10.30.82]) (Authenticated sender: vik@postgresfriends.org) by relay4-d.mail.gandi.net (Postfix) with ESMTPSA id 48137E0009; Wed, 1 Jul 2020 20:31:26 +0000 (UTC) Subject: Re: SQL-standard function body To: Pavel Stehule Cc: Robert Haas , Tom Lane , Peter Eisentraut , pgsql-hackers References: <1c11f1eb-f00c-43b7-799d-2d44132c02d7@2ndquadrant.com> <493812.1593541480@sss.pgh.pa.us> <494838.1593543098@sss.pgh.pa.us> From: Vik Fearing Message-ID: <61fa89a9-c39f-f780-1bf0-9ff4d387a9da@postgresfriends.org> Date: Wed, 1 Jul 2020 22:31:26 +0200 User-Agent: Mozilla/5.0 (X11; Linux x86_64; rv:68.0) Gecko/20100101 Thunderbird/68.8.0 MIME-Version: 1.0 In-Reply-To: Content-Type: text/plain; charset=utf-8 Content-Language: en-US Content-Transfer-Encoding: 8bit List-Id: List-Help: List-Subscribe: List-Post: List-Owner: List-Archive: Precedence: bulk On 7/1/20 9:32 PM, Pavel Stehule wrote: > st 1. 7. 2020 v 20:19 odesílatel Vik Fearing > napsal: > >> On 7/1/20 3:36 PM, Robert Haas wrote: >>> I actually don't have a very clear idea of what the standard has to >>> say about SQL-language functions. Does it just say it's a list of >>> statements, or does it involve variables and control-flow constructs >>> and stuff like that, too? >> >> >> It's either a single sql statement, or a collection of them between >> "begin atomic" and "end". There are no variables or flow control >> constructs or anything like that, just as there are no such things >> outside of a function. >> > > What is the source of this comment? The SQL Standard. > Maybe we are speaking (and thinking) > about different languages. I think so, yes. > I thought the language of SQL functions (ANSI/SQL) is SQL/PSM. That is something else entirely, and not at all what Peter's patch is about. -- Vik Fearing