Re: SQL Statement for Resetting Serial Column ?
Posted in 1997
Roger Tomas — — source: Informix-list mailing list archive (1991-1998)
Terron Wright wrote: > > Can someone give me a good example of how to use the alter table > statement for resetting a serial column next number. I know that the documentation mentions that you can use ALTER TABLE to reset a serial column, but I have yet to figure it out. Instead, you should insert the maximum allowed value into the serial column and force it to cycle back to 1. You can then delete the row if you don't want it. We do this for populating databases with test data so that we can get reproducible results (ie. get the same serial values out of the database). ----------- Roger Tomas AG Communication Systems