Re: [GENERAL] sequences and Transactions

2000-04-27 Thread Bruce Momjian
> Hi! > > how can I setup sequences to have the current-value reset in case > of an Transaction rollback. > > My intension is to get an contignous numbering of the rows. > Currently in case of an Rollback one number is skipped since > the record itself is not inserted but the counter is not r

RE: [GENERAL] sequences and Transactions

2000-04-27 Thread Michael Ansley
Title: RE: [GENERAL] sequences and Transactions You can't.  Sequences are not designed for continuity, they are designed for uniqueness.  If you want to have a set of contiguous numbers, in ascending order, then you will probably have to write a trigger to insert the next value, which i

[GENERAL] sequences and Transactions

2000-04-27 Thread Elmar . Haneke
Hi! how can I setup sequences to have the current-value reset in case of an Transaction rollback. My intension is to get an contignous numbering of the rows. Currently in case of an Rollback one number is skipped since the record itself is not inserted but the counter is not reset. Elmar