How to delete table contents and reset autonumber counters

  • Thread starter Thread starter Siegfried Heintze
  • Start date Start date
S

Siegfried Heintze

When I delete my table contents (but not the table definitions) the auto
number counters are not reset. Is there a way to reset them?

Thanks,
Siegfried
 
Simplest way is to compact the database after deleting all records. That
should work in all versions of Access: if not, apply the latest service
packs for Office and JET, from:
http://support.microsoft.com/gp/sp

If you need to do it programmatically, it is possible in Access 2000 and
later to set the Seed of the Column in the Table, using the ADOX library.
There's a (rather involved) example of how to use these properties in this
link:
http://allenbrowne.com/ser-40.html
 
Back
Top