Re: Resetting of serial number field
Posted in 1997
Sekhar Bhami contra wrote: > > Hi, > > How do I reset the "serial number" field in a table? For eg. table X > has a serial field. If I add 10 records and delete all of them, > then the next record has the serial number of 11. How do I reset this > number to 1? Note that If I drop the table, the serial number starts > from 1. You can't. I posted about a year ago how the serial field worked with SE, Online is pretty much the same. The logic is this: LET S = serial counter. LET F = serial field in. LET T = Table IF (F) == 0 THEN T(F) = S++; ELSE IF F > S THEN S==F; T(F) == F; END IF I realize that this is simplistic but it is the best I can do on short notice. When you recreate the table, the serial field is initialized to 1 HTH -Mike -- #include <std_disclaimer.h> /* Mike Segel (MS385) */ #include <No_Spam.h> #ifdef OFFENDED_BY_CONTENT The author takes no responsibility for this post. Any resemblence to a coherent rational thought is purely coincidence. -The Management. #endif ***************************** Due to AGIS's Refusal to Act Responsibly We are blocking all of their domains at the packet level. This block will exist until AGIS modifies their policies to conform to existing RFCs and net community standards. We encourage all ISPs and domain holders to do the same. *****************************