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 1nH6Qr-0000iU-3y for pgsql-hackers@arkaria.postgresql.org; Mon, 07 Feb 2022 16:00:01 +0000 Received: from localhost ([127.0.0.1] helo=malur.postgresql.org) by malur.postgresql.org with esmtp (Exim 4.92) (envelope-from ) id 1nH6Qp-0005Qe-ND for pgsql-hackers@arkaria.postgresql.org; Mon, 07 Feb 2022 15:59:59 +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 1nH6Qp-0005QU-Dv for pgsql-hackers@lists.postgresql.org; Mon, 07 Feb 2022 15:59:59 +0000 Received: from out3-smtp.messagingengine.com ([66.111.4.27]) by magus.postgresql.org with esmtps (TLS1.3:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.92) (envelope-from ) id 1nH6Qj-0006mj-Df for pgsql-hackers@postgresql.org; Mon, 07 Feb 2022 15:59:58 +0000 Received: from compute2.internal (compute2.nyi.internal [10.202.2.46]) by mailout.nyi.internal (Postfix) with ESMTP id AC5465C0193; Mon, 7 Feb 2022 10:59:51 -0500 (EST) Received: from mailfrontend2 ([10.202.2.163]) by compute2.internal (MEProxy); Mon, 07 Feb 2022 10:59:51 -0500 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d= messagingengine.com; h=cc:content-transfer-encoding:content-type :date:date:from:from:in-reply-to:in-reply-to:message-id :mime-version:references:reply-to:sender:subject:subject:to:to :x-me-proxy:x-me-proxy:x-me-sender:x-me-sender:x-sasl-enc; s= fm2; bh=Bta20t7sQZSDUlaYTThjQ/IL7sCLEBOgvukgsI+Cseg=; b=nqExLS4b iIqh6wxYbvFzqvHNZ70rFkvSDz84e8ZuM49SQ+wsXvIMc6RbloHY9wS9s2zmECwS OkV47TO9/kXNfeir18l40rW1d4SG8OfiFGED09rcU6B2SCERAZo0Y3yu4wD3Ncmp +RHKR9od/kB3rMag//FDvPFFe1SVEBE/BKB8duMX1TsgUurotl1sQJaVwbbgOjr4 uxPjKXIaqUn4n2LmXII/K2czgTrMocDZozKhUt0pQFf/G37F1V/WfTtDWIWEXHTR S13g27PwqnLXUiU+kUrarhEGP9IvcrlMMRz5d5Ez3nx0b1r1/QPxIAcdfAMJsre+ lfy8uAsUqX6PiA== X-ME-Sender: X-ME-Received: X-ME-Proxy-Cause: gggruggvucftvghtrhhoucdtuddrgedvvddrheehgdektdcutefuodetggdotefrodftvf curfhrohhfihhlvgemucfhrghsthforghilhdpqfgfvfdpuffrtefokffrpgfnqfghnecu uegrihhlohhuthemuceftddtnecusecvtfgvtghiphhivghnthhsucdlqddutddtmdenuc fjughrpefkffggfgfuvfhfhfgjtgfgsehtjeertddtfeejnecuhfhrohhmpefrvghtvghr ucfgihhsvghnthhrrghuthcuoehpvghtvghrrdgvihhsvghnthhrrghuthesvghnthgvrh hprhhishgvuggsrdgtohhmqeenucggtffrrghtthgvrhhnpeefjeegheetuefhveevudel ueeftdejteeiffetvdduhfdtieefgfeutedtveeggfenucevlhhushhtvghrufhiiigvpe dtnecurfgrrhgrmhepmhgrihhlfhhrohhmpehpvghtvghrrdgvihhsvghnthhrrghuthes vghnthgvrhhprhhishgvuggsrdgtohhm X-ME-Proxy: Received: by mail.messagingengine.com (Postfix) with ESMTPA; Mon, 7 Feb 2022 10:59:49 -0500 (EST) Message-ID: Date: Mon, 7 Feb 2022 16:59:48 +0100 MIME-Version: 1.0 User-Agent: Mozilla/5.0 (Macintosh; Intel Mac OS X 10.15; rv:91.0) Gecko/20100101 Thunderbird/91.5.1 Subject: Re: Documentation about PL transforms Content-Language: en-US To: Chapman Flack , PostgreSQL Hackers References: <61FDBCFE.3090800@anastigmatix.net> From: Peter Eisentraut In-Reply-To: <61FDBCFE.3090800@anastigmatix.net> Content-Type: text/plain; charset=UTF-8; format=flowed Content-Transfer-Encoding: 7bit List-Id: List-Help: List-Subscribe: List-Post: List-Owner: List-Archive: Archived-At: Precedence: bulk On 05.02.22 00:55, Chapman Flack wrote: > I'm thinking plhandler.sgml is the only place that really needs to be > said; readers looking up CREATE TRANSFORM and using an existing PL that > supports it don't need to know how the sausage is made. (Maybe it is > worth mentioning there, though, that it isn't possible to develop > transforms for an arbitrary PL unless that PL applies transforms.) makes sense > I noticed the CREATE TRANSFORM docs show the argument list as > (argument_type [, ...]) even though check_transform_function will reject > any argument list of length other than 1 or with type other than internal. > Is that an overly-generic way to show the syntax, or is that a style > with precedent elsewhere in the docs? That could be corrected. > As long as a PL handler has the sole responsibility for invoking > its transforms, I wonder if it would make sense to allow a PL to > define what its transforms should look like, maybe replacing > check_transform_function with a transform_validator for the PL. > I'm not proposing such a patch here, but I am willing to prepare > one for plhandler.sgml and maybe pltemplate.c documenting the current > situation, if nobody tells me I'm wrong about something here. Maybe. This kind of thing would mostly be driven what a PL wants in actual practice, and then how that could be generalized to many/all PLs.