Re: proposal: schema variables - Mailing list pgsql-hackers

From Jim Jones
Subject Re: proposal: schema variables
Date
Msg-id 9d6897bd-855d-44a6-8ebe-17b2b1d04430@uni-muenster.de
Whole thread Raw
In response to Re: proposal: schema variables  (Pavel Stehule <pavel.stehule@gmail.com>)
Responses Re: proposal: schema variables
List pgsql-hackers
Hi

On 9/13/25 11:28, Pavel Stehule wrote:
> 
> minor change (after private talk with Jim Jones)
> 

After another pass, there are a few additional tests that should be
included in this patch:


== Additional tests for GRANT x ON VARIABLE ==
==============================================

We wanna make sure the proper error message is raised.

postgres=# GRANT INSERT ON VARIABLE var TO jim;
ERROR:  invalid privilege type INSERT for session variable

postgres=# GRANT DELETE ON VARIABLE var TO jim;
ERROR:  invalid privilege type DELETE for session variable


== Tests for ALTER DEFAULT PRIVILEGES ==
========================================

I couldn't find regression tests for ALTER DEFAULT PRIVILEGES ... if I
haven't just missed them, I think they'd be a nice addition.

postgres=# ALTER DEFAULT PRIVILEGES IN SCHEMA s GRANT UPDATE ON
VARIABLES TO jim;
ALTER DEFAULT PRIVILEGES

postgres=# ALTER DEFAULT PRIVILEGES IN SCHEMA s GRANT INSERT ON
VARIABLES TO jim;
ERROR:  invalid privilege type INSERT for session variable

postgres=# ALTER DEFAULT PRIVILEGES IN SCHEMA s GRANT DELETE ON
VARIABLES TO jim;
ERROR:  invalid privilege type DELETE for session variable

postgres=# ALTER DEFAULT PRIVILEGES IN SCHEMA s GRANT SELECT ON
VARIABLES TO jim;
ALTER DEFAULT PRIVILEGES


Best, Jim



pgsql-hackers by date:

Previous
From: Chao Li
Date:
Subject: Re: Fix missing EvalPlanQual recheck for TID scans
Next
From: Aleksander Alekseev
Date:
Subject: Re: [PATCH] Refactor bytea_sortsupport(), take two