All; I have some code to delete all data from a table, then reload it with an append query. Is there a way to reset the autonumber of the table I am adding the data to when it is empty? Thanks
All; I have some code to delete all data from a table, then reload it with an append query. Is there a way to reset the autonumber of the table I am adding the data to when it is empty? Thanks
Bing: Access reset autonumber
http://support.microsoft.com/kb/812718
How to attach file: http://www.accessforums.net/showthread.php?t=70301 To provide db: copy, remove confidential data, run compact & repair, zip w/Windows Compression.
I'm trying to do this during executing my code after I delete the data from this table:
I get invalid field type.Code:Dim strSql As String strSql = "ALTER TABLE tblMstr ALTER COLUMN ID1 COUNTER(1,1)" DoCmd.RunSQL strSql
That doesn't appear to be what is described in the link. I doubt can do this with ALTER sql.
Run Compact & Repair to reset empty table autonumber.
How to attach file: http://www.accessforums.net/showthread.php?t=70301 To provide db: copy, remove confidential data, run compact & repair, zip w/Windows Compression.
Here's a link to two methods:
http://access.mvps.org/access/tables/tbl0005.htm
Linq ;0)>
The problem with making anything foolproof...is that fools are so darn ingenious!
All posts/responses based on Access 2003/2007