Re: Bug or feature? - Mailing list pgsql-hackers

From Tom Lane
Subject Re: Bug or feature?
Date
Msg-id 9858.989686099@sss.pgh.pa.us
Whole thread Raw
In response to Re: Bug or feature?  (Olivier PRENANT <ohp@pyrenet.fr>)
Responses Re: Bug or feature?  (Olivier PRENANT <ohp@pyrenet.fr>)
List pgsql-hackers
Olivier PRENANT <ohp@pyrenet.fr> writes:
> Shoudn't postgres extend priviledges to the sequences generated by a
> create table ???

That's not clear.  The sequence is an independent object.  Had you
explicitly done
CREATE SEQUENCE myseq;
CREATE TABLE mytab (f1 int default nextval('myseq'));

would you expect that granting permissions on mytab automatically
grants them on myseq as well?  I think you might consider that
surprising.  But there isn't any difference between this and what
CREATE TABLE does.

There have been suggestions in the past that SERIAL should be a "real
data type" with the sequence object being hidden more effectively than
it is now --- including auto-dropping it at table deletion, etc.
If that were to happen then the permissions issue would probably go away
too.  It doesn't seem to be a very high priority for anyone, though.
        regards, tom lane


pgsql-hackers by date:

Previous
From: Olivier PRENANT
Date:
Subject: Re: Bug or feature?
Next
From: Olivier PRENANT
Date:
Subject: Re: Bug or feature?