> > I think there are two completely different issues here: one is what
> > name to use for the auto-generated sequence, and the other is whether
> > (when) to drop the sequence if the table is dropped. Fixing the
> > latter issue would reduce but not entirely eliminate the issue of
> > name collisions.
>
> Hmmm? No way - see below.
>
> > IIRC, the major objection to the notion of adding random hash characters
> > to the auto-generated names was that people wanted to be able to predict
> > the names. There was a long discussion about this a couple years back
> > when we settled on the present algorithm. Please search the archives
> > a bit if you want to re-open that issue.
>
> I will search the archives, but I'll explain my thoughts here a well.
>
> Well, what's the problem with appending a number - that's how index names
> get generated.
>
> This is my horrible schema that forced me to abandon using SERIAL in favour
> of explicit CREATE SEQUENCE statements:
Added to TODO:
* Have SERIAL generate non-colliding sequence names when we have auto-destruction
-- Bruce Momjian | http://candle.pha.pa.us pgman@candle.pha.pa.us | (610)
853-3000+ If your life is a hard drive, | 830 Blythe Avenue + Christ can be your backup. | Drexel Hill,
Pennsylvania19026