Resetting all tables back to zero

T

traveler

I am nearing completion of a new application and I want to clear out all the
data tabkes and reset the auto-numbered values back to zero. I noticed that
this was done when I originally split the front end from the back end. Is
there an easy way to do it now? I tried deleting all the rows in the tables
but the auto-numbered fields don't reset to zero.

Traveler
 
G

George Nicholson

Auto numbers should reset to Max(ID) +1 when you compact the database.
(i.e., delete all existing records, then compact. Autonumbers should now
start at 1)
 
S

Steve Schapel

George,

Just a slight clarification here... An Autonumber will, as you suggest,
reset to 1 if the database is compacted after deleting all records. But
compacting when there is still data inthe table will not reset the
Autonumber seed value.
 
G

George Nicholson

But compacting when there is still data in the table will not reset the
Autonumber seed value.

Right you are.

I could have *sworn* that I had seen that behavior, but, of course, can't
seem to recreate it.

Good thing I wasn't counting on it, I guess. Hope the OP wasn't either.
 
S

Steve Schapel

George,

This was the case in Access 97 and Access 7. Probably should be
classified as a bug :)
 
Top