Inconsistent syntax in GRANT - Mailing list pgsql-hackers

From Josh Berkus
Subject Inconsistent syntax in GRANT
Date
Msg-id 200601031719.41604.josh@agliodbs.com
Whole thread Raw
Responses Re: Inconsistent syntax in GRANT
List pgsql-hackers
Folks,

Just got tripped up by this:

GRANT SELECT ON table1 TO someuser;
GRANT SELECT ON table1_id_seq TO someuser;
.... both work

However,
GRANT SELECT ON TABLE table1 TO someuser; 
... works, while ....
GRANT SELECT ON SEQUENCE table1_id_seq TO someuser;
... raises an error.

This is inconsistent.   Do people agree with me that the parser should 
accept "SEQUENCE" there, since the optional object name works for all 
other objects?  Is there some technical reason this is difficult to do?

-- 
--Josh

Josh Berkus
Aglio Database Solutions
San Francisco


pgsql-hackers by date:

Previous
From: Josh Berkus
Date:
Subject: Re: [Bizgres-general] WAL bypass for INSERT, UPDATE and
Next
From: David Fetter
Date:
Subject: Deferrable UNIQUE INDEX?