Ahh makes sense, thanks for the explanation!
I was assuming USING() clauses were executed in the context of the
owner of the policy, by passing RLS.
2016-12-17 13:18 GMT-05:00 Joe Conway :
> On 12/17/2016 01:01 PM, Simon Charette wrote:
>> Thanks a lot Joe, that seems to work!
>
&g
On 12/16/2016 01:02 AM, Simon Charette wrote:
>> Unfortunately this will only return accounts matching the current_user's
>> name.
>>
>> I would expect "SET ROLE foo; SELECT name FROM accounts" to return "foo" and
>> &qu
16-12-16 0:57 GMT-05:00 Charles Clavadetscher :
> Hello
>
>> -Original Message-
>> From: pgsql-general-ow...@postgresql.org
>> [mailto:pgsql-general-ow...@postgresql.org] On Behalf Of Simon Charette
>> Sent: Freitag, 16. Dezember 2016 06:15
>> To: pgsql
Hello there,
I'm not sure I'm posting to the appropriate mailing list so don't hesitate to
redirect me to the appropriate one.
I've been trying to setup a policy that allows "accounts" table rows to only be
seen by their owner by using the current_user to compare them by name.
Unfortunately it l