pg.ddx.io pgsql-admin@postgresql.org mailing list archive
help / color / mirror / Atom feedUser has role, role has UPDATE, user can't update, cannot figure this out.
3+ messages / 2 participants
[nested] [flat]
* User has role, role has UPDATE, user can't update, cannot figure this out.
@ 2021-03-05 21:41 Wells Oliver <wells.oliver@gmail.com>
0 siblings, 1 reply; 3+ messages in thread
From: Wells Oliver @ 2021-03-05 21:41 UTC (permalink / raw)
To: pgsql-admin
It seems very straight forward, but I have a user belongs to the role
analyst, and the role analyst has the permission to UPDATE, e.g..
GRANT REFERENCES, UPDATE ON TABLE myschema.mytable TO analyst;
But the user gets a permission denied error on the table for a simple
UPDATE query. I can't figure it out: no trigger functions. A few FKs, but
nothing complex. Is there a way to figure out why this user is being denied
permission?
--
Wells Oliver
wells.oliver@gmail.com <wellsoliver@gmail.com>
^ permalink raw reply [nested|flat] 3+ messages in thread
* Re: User has role, role has UPDATE, user can't update, cannot figure this out.
@ 2021-03-05 22:08 Stephen Frost <sfrost@snowman.net>
parent: Wells Oliver <wells.oliver@gmail.com>
0 siblings, 1 reply; 3+ messages in thread
From: Stephen Frost @ 2021-03-05 22:08 UTC (permalink / raw)
To: Wells Oliver <wells.oliver@gmail.com>; +Cc: pgsql-admin
Greetings,
* Wells Oliver (wells.oliver@gmail.com) wrote:
> It seems very straight forward, but I have a user belongs to the role
> analyst, and the role analyst has the permission to UPDATE, e.g..
>
> GRANT REFERENCES, UPDATE ON TABLE myschema.mytable TO analyst;
>
> But the user gets a permission denied error on the table for a simple
> UPDATE query. I can't figure it out: no trigger functions. A few FKs, but
> nothing complex. Is there a way to figure out why this user is being denied
> permission?
Is there a WHERE clause for the UPDATE? If so, then the role also needs
SELECT rights.
Thanks,
Stephen
Attachments:
signature.asc (application/pgp-signature, 818B) download
^ permalink raw reply [nested|flat] 3+ messages in thread
* Re: User has role, role has UPDATE, user can't update, cannot figure this out.
@ 2021-03-05 22:34 Wells Oliver <wells.oliver@gmail.com>
parent: Stephen Frost <sfrost@snowman.net>
0 siblings, 0 replies; 3+ messages in thread
From: Wells Oliver @ 2021-03-05 22:34 UTC (permalink / raw)
To: Stephen Frost <sfrost@snowman.net>; +Cc: pgsql-admin
That's it exactly. That's incredible, so basic, and I never knew you needed
SELECT to make qualified UPDATES.
Thanks Stpehen.
On Fri, Mar 5, 2021 at 2:08 PM Stephen Frost <sfrost@snowman.net> wrote:
> Greetings,
>
> * Wells Oliver (wells.oliver@gmail.com) wrote:
> > It seems very straight forward, but I have a user belongs to the role
> > analyst, and the role analyst has the permission to UPDATE, e.g..
> >
> > GRANT REFERENCES, UPDATE ON TABLE myschema.mytable TO analyst;
> >
> > But the user gets a permission denied error on the table for a simple
> > UPDATE query. I can't figure it out: no trigger functions. A few FKs, but
> > nothing complex. Is there a way to figure out why this user is being
> denied
> > permission?
>
> Is there a WHERE clause for the UPDATE? If so, then the role also needs
> SELECT rights.
>
> Thanks,
>
> Stephen
>
--
Wells Oliver
wells.oliver@gmail.com <wellsoliver@gmail.com>
^ permalink raw reply [nested|flat] 3+ messages in thread
end of thread, other threads:[~2021-03-05 22:34 UTC | newest]
Thread overview: 3+ messages (download: mbox mbox.gz follow: Atom feed)
-- links below jump to the message on this page --
2021-03-05 21:41 User has role, role has UPDATE, user can't update, cannot figure this out. Wells Oliver <wells.oliver@gmail.com>
2021-03-05 22:08 ` Stephen Frost <sfrost@snowman.net>
2021-03-05 22:34 ` Wells Oliver <wells.oliver@gmail.com>
This inbox is served by DDX for PostgreSQL; see mirroring instructions
for how to clone and mirror all data and code used for this inbox