Sequence privileges - Mailing list pgsql-hackers

From Peter Eisentraut
Subject Sequence privileges
Date
Msg-id Pine.LNX.4.44.0205181720310.4819-100000@localhost.localdomain
Whole thread Raw
Responses Re: Sequence privileges
List pgsql-hackers
The documentation of the sequence privileges on the GRANT reference page
doesn't match the code.

Documented:

currval:    UPDATE
nextval:    UPDATE
setval:        UPDATE

Actual:

currval:    SELECT
nextval:    UPDATE
setval:        UPDATE

But shouldn't it more ideally be

currval:    SELECT
nextval:    SELECT + UPDATE
setval:        UPDATE

because nextval allows you to infer the content of the sequence?  (Cf.
UPDATE tab1 SET a = b requires SELECT + UPDATE on tab1.)

-- 
Peter Eisentraut   peter_e@gmx.net



pgsql-hackers by date:

Previous
From: Tom Lane
Date:
Subject: Re: Updated CREATE FUNCTION syntax
Next
From: Tom Lane
Date:
Subject: Re: Poster(s) needed