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.98.2) (envelope-from ) id 1xECrT-00000000z9I-3yIY for pgsql-general@arkaria.postgresql.org; Tue, 06 Oct 2026 21:38:12 +0000 Received: from localhost ([127.0.0.1] helo=malur.postgresql.org) by malur.postgresql.org with esmtp (Exim 4.98.2) (envelope-from ) id 1xECrR-00000002596-2Kf0 for pgsql-general@arkaria.postgresql.org; Tue, 06 Oct 2026 21:38:09 +0000 Received: from magus.postgresql.org ([2a02:c0:301:0:ffff::29]) by malur.postgresql.org with esmtps (TLS1.3) tls TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384 (Exim 4.98.2) (envelope-from ) id 1xECrQ-0000000258y-3Z5k for pgsql-general@lists.postgresql.org; Tue, 06 Oct 2026 21:38:09 +0000 Received: from fhigh-b8-smtp.messagingengine.com ([202.12.124.159]) by magus.postgresql.org with esmtps (TLS1.3) tls TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384 (Exim 4.98.2) (envelope-from ) id 1xECrN-00000000mGr-3har for pgsql-general@postgresql.org; Tue, 06 Oct 2026 21:38:08 +0000 Received: from phl-compute-11.internal (phl-compute-11.internal [10.202.2.51]) by mailfhigh.stl.internal (Postfix) with ESMTP id 36FD27A0189 for ; Tue, 6 Oct 2026 17:38:03 -0400 (EDT) Received: from phl-frontend-03 ([10.202.2.162]) by phl-compute-11.internal (MEProxy); Tue, 06 Oct 2026 17:38:03 -0400 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=aklaver.com; h= cc:content-transfer-encoding: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=1791322682; x=1791409082; bh=I6n1lGwWrkSoUhoXSIOgdQx+Qp3x4gfs/8azjdERnGs=; b= O0wN9ztzlcnu/n79a+OZ1t+A9jb5dG0TwrkgQ43SQybc0GGIWLbEzu2/3G+b0lZo 1ILbudInBft2J7g4L1RWKgacjUkaHKriiebnrmy3g5lelVdWTVCuN9Ve4pB9aqIi PDDLnMqRrZqn+GBEOeDnwlDUd0oklSbPI2iVCVCMp9J/KiKvnIkYpOST52N1ewQQ JvtSoXjztO4+uo+oUeyfdReRcjNeloV3qH10lNiOkej/xcKSs5Ez8VbG0fWEIJfX V3AAMBOhddK2dM2IzjxVX5DBl6h4b48wnL88TGVirYhT9DpuCCk6CiQXiONQCFNc 3uqRrZ5mTKPCDOHLSvGgEw== DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d= messagingengine.com; h=cc:content-transfer-encoding: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-sender :x-me-sender:x-sasl-enc; s=fm2; t=1791322682; x=1791409082; bh=I 6n1lGwWrkSoUhoXSIOgdQx+Qp3x4gfs/8azjdERnGs=; b=hR5+TzqbmY2Lrw/Sr XMIi8C1VvEUAlpxKuPsVOuptfRhbumozNgaUnKLQO4STHEdXT7ay3lPx/JOzouJo ldtxcKVT/x8W1Tlhnqw8zzVdl+DvU93bC+tB/si4hPo5w6CqDamW4fnJY1VjQUXY oK3hpl7j3GDxQQWU5QKUqHG/MoC8b3VuH39XKoH+AknuNL8LGI46kGN6YgIon0cN 6Yyu4cQ+fXImd8vWmQUuAAzRzSnFEwKsl81iHlWCkobQfPNByZpaYR8Xv9VugzdY XF/6SfpQqbI/X0ZU6jASMvfm6mCMlan3wTJImSDJqVFZQf925fojclHsLGIiAGee OXiEQ== X-DKIM2-Info: draft=ietf-dkim-dkim2-spec-06; repo=github.com/dkim2wg/interop; date=2026-10-04; sw=lmtpprox; action=sign d=aklaver.com a=rsa-sha256; DKIM2-Signature: i=1; m=1; t=1791322682; d=aklaver.com; mf=PGFkcmlhbi5rbGF2ZXJAYWtsYXZlci5jb20+; rt=PHBnc3FsLWdlbmVyYWxAcG9zdGdyZXNxbC5vcmc+; s=fm1:rsa-sha256:v/xJ7ZNeQqZZjfbtdB8x0pBeLkeDf1E+fRSKmJV4K2oW2zs M3NAIegWLNqKS5ELT96zrzE8ZqKI+lH+EToDk8Vy67QbWnAS6nASfgkbOSZ2AsA4 voSfMZTpIdqdrhX7lCVHAjeFt0DbSNBllnyD61O9qZpAHRNneqQsEkMXqknkrEXS NId0ZcRtmBBzWb1ijyb3bhAON+zmRJc+HdNJTuSAwO0p08aS8okmT+eOTn9Qw8eV 4xNPi/8v2AQwJl1JFLLkywBxC0QPEvvX8Gx5CUG/yvMUdosgcM1JqK6z2H0OGeaG HybSTntVPjBr9DhUjC2mPs/4FZtkXzq3GTXMwUw==; X-DKIM2-Info: draft=ietf-dkim-dkim2-spec-06; repo=github.com/dkim2wg/interop; date=2026-10-04; sw=lmtpprox; action=mi-m=1; hc=13; hn=content-language,content-transfer-encoding,content-type,date, feedback-id,from,in-reply-to,message-id,mime-version,references, subject,to,user-agent; Message-Instance: m=1; h=sha256:n7tTlDHFpK8h21QKzVpSXplprfOh5Oe+FUz1Q4jg48w=:QDDngG8JJNA0rlgASvTB5MJDghw3Bvf+eR9ud8aNrac=; X-ME-Sender: X-ME-Received: X-ME-Proxy-Cause: dmFkZTFtigbOSOTKwwkaXAEz4lpwwAoYlkYjHaPhQnSxE4zyBvyYm11I7iytZO4XNEIiaS K+1Gp4wl4xg5d3cd3MFCKYZ5nhVJJM/tOl1DEOyap+bRpKroBxQV61oszlu54kVuxBhv05 qyrmqS/9+0qi6ns6RRkIv2I6hdTP/MZMa5J8f8t7WkZOnv6UWe1kkkVFuD7AoIyqDRqIBn sc+qawSN8u3VMv8sdqtjU4mxOi3+D+WraMkuBTMUs8fHgEhUee3TQ2Nl1sYIz0RxvBXtCB VnCdhKDGeeugVieJmQzQXybt7uEfseFz3VddSQBNFjh7xEnmHJ2nazyffGVzmwfMpfFooi EKHpVS1BrUephXXjwBxMm5OMkid6hDHpTo0eUIxA0QyxjQLFiEiI2kG8KpQPVITj8dZUuH TGwc4mwTu87RKAHYgO1VKgQj9tk4l7tJi9z1OR9A83mWg3LEVOwRRxQPYqPuo261xgAC0Y LluOiOmY6DPpfLJHmYFT9NlvassG+ot12qj8M0ctEnoY9i++yv5qcBC+p3EKw+BTYtJ/6T zz8JlylvjYPP9ghPRS6QsIGpP0Ou8T2VgOJsu3ygFgqBSU0Pjqmrz7Dwo/6+g5EOswmmkr WthIl6aKXWAATXaMYrIurZORdKruBweozvRdHBmcEM8r5FG0yAgEu4mtlQWQ X-ME-Proxy: Feedback-ID: i76984098:Fastmail Received: by mail.messagingengine.com (Postfix) with ESMTPA; Tue, 6 Oct 2026 17:38:01 -0400 (EDT) Message-ID: <0f484041-00b6-454b-9def-e14a955d7c69@aklaver.com> Date: Tue, 6 Oct 2026 14:38:00 -0700 MIME-Version: 1.0 User-Agent: Mozilla Thunderbird Subject: Re: AW: Why is materialized view creation a "security-restricted operation"? To: =?UTF-8?Q?F=C3=A4rber=2C_Franz-Josef_=28StMUK=29?= , "pgsql-general@postgresql.org" References: <77826d7580a9488ca28eb4bcfe94aa37@stmuk.bayern.de> <61488cb9-5b84-449a-9886-e0d3b9671aa6@aklaver.com> <886a7a1fb54a4abdbb89897a6854edd7@stmuk.bayern.de> Content-Language: en-US From: Adrian Klaver In-Reply-To: <886a7a1fb54a4abdbb89897a6854edd7@stmuk.bayern.de> Content-Type: text/plain; charset=UTF-8; format=flowed Content-Transfer-Encoding: 8bit List-Id: List-Help: List-Subscribe: List-Post: List-Owner: List-Archive: Archived-At: Precedence: bulk On 10/6/26 1:20 AM, Färber, Franz-Josef (StMUK) wrote: > Are you sure the extension pgtt would work in my case? > > https://github.com/darold/pgtt#how-the-extension-really-works says: > > "the first access to the table using a SELECT, UPDATE or DELETE statement will produce the creation of a temporary table" > > Well, my original point was: Creation of a temporary table is prohibited due to "security-restricted operation". I tried your MATERIALIZED VIEW with pgtt and ran into the temporary table issue. I tried also against the 'template' table behind the temporary tables and got a little further but the behavior was unstable. I suspect a bug that allowed me to get that far. Questions: 1) Why the MATERIALIZED VIEW? 2) Can you provide an overview in pseudo code, including the part in the function, of the process you are trying create? > > > Regards, > Franz-Josef Färber > > > -----Ursprüngliche Nachricht----- > Von: Adrian Klaver > Gesendet: Freitag, 2. Oktober 2026 16:55 > An: Ron Johnson ; pgsql-general > Betreff: Re: Why is materialized view creation a "security-restricted operation"? > > On 10/2/26 3:19 AM, Ron Johnson wrote: >> On Thu, Oct 1, 2026 at 8:35 PM David G. Johnston >> > wrote: >> >> On Thu, Oct 1, 2026 at 4:56 PM Ron Johnson > > wrote: >> >> A GLOBAL TEMP table (where the DBA runs the CREATE GLOBAL TEMP >> TABLE once (so that CREATE TEMP TABLE some_table  everywhere >> that my_func() is called) would also solve OP's problem. >> >> >> Per the create table docs: >> >> "Optionally, GLOBAL or LOCAL can be written before TEMPORARY or >> TEMP. This presently makes no difference in PostgreSQL and is >> deprecated; see Compatibility below." >> >> And I'm praying for "since future versions of PostgreSQLmight adopt a >> more standard-compliant interpretation of their meaning" in the >> Compatibility section you referenced. > > As an extension there is: > > https://github.com/darold/pgtt > >> >> -- >> Death to , and butter sauce. >> Don't boil me, I'm still alive. >> lobster! > >