On Sun, Apr 30, 2006 at 11:06:05AM +0200, Magnus Hagander wrote: > If it's not obvious yet :-P, I'd be in favour of having SERIAL as > black-box as possible, and then just use manual CREATE SEQUENCE and > DEFAULT nextval() for when you need a more advanced case. But that's as > seen from a user perspective, without regard for backend complexity.
That's where I sit as well. SERIAL as a macro has no value to me. I'd rather write it out in full, and make it obvious to the caller, what I'm doing. This way, I get to choose the sequence name instead of having it generated for me, and the GRANT expression makes more sense. If SERIAL generated an 'anonymous' SEQUENCE, that was a real black box, that had the same permissions as the table, I'd be tempted to use it again. I also see the db_dump example as proving more that the box isn't black enough, than proving that the black box approach is wrong. Cheers, mark -- [EMAIL PROTECTED] / [EMAIL PROTECTED] / [EMAIL PROTECTED] __________________________ . . _ ._ . . .__ . . ._. .__ . . . .__ | Neighbourhood Coder |\/| |_| |_| |/ |_ |\/| | |_ | |/ |_ | | | | | | \ | \ |__ . | | .|. |__ |__ | \ |__ | Ottawa, Ontario, Canada One ring to rule them all, one ring to find them, one ring to bring them all and in the darkness bind them... http://mark.mielke.cc/ ---------------------------(end of broadcast)--------------------------- TIP 1: if posting/reading through Usenet, please send an appropriate subscribe-nomail command to [EMAIL PROTECTED] so that your message can get through to the mailing list cleanly