Re: user space function "is_power_user" - Mailing list pgsql-hackers

From Pavel Stehule
Subject Re: user space function "is_power_user"
Date
Msg-id CAFj8pRADUygh9z9Lef7y_t1qinCFYhoDDTiO03rnCkG_-NFSug@mail.gmail.com
Whole thread Raw
In response to Re: user space function "is_power_user"  (Heikki Linnakangas <hlinnaka@iki.fi>)
List pgsql-hackers


2015-06-22 11:20 GMT+02:00 Heikki Linnakangas <hlinnaka@iki.fi>:
On 06/22/2015 09:51 AM, Pavel Stehule wrote:
Hi

I often need a function for identification if current user is database
owner or is superuser.

It can be pretty simply implemented in C level.

Do you think it should be available in core?

current_setting('is_superuser');

there is second constraint

OR "is database owner"

Pavel
 

- Heikki


pgsql-hackers by date:

Previous
From: Heikki Linnakangas
Date:
Subject: Re: user space function "is_power_user"
Next
From: Tom Lane
Date:
Subject: Re: Extension support for postgres_fdw