Karen has attended:
Access Introduction course
Access primary key
our current database which contains over 7000 entries is now counting up incorrectly so where it may say in the bottom left counter 7000 it is in fact in the record saying 7006 - can this be resolved so it shows the correct and same record number in the count box and in the record?
RE: Access primary key
Hi Karen
Thank you for your question
If I understand you correctly your table has 7000 records, while the autonumber primary key field shows the last record as 7006.
This is most likely to be because records have been deleted from the table. If this happens access does not automatically recalculate the autonumbers, but will carry on from the last number enetered. So if you type in record number 1000 and then delete it. The next number entered would be 1001, leaving 1000 effectively blank.
To fix this you would need to click on tools-Database utilities-compact and repair.
Note this will recalculate the autonumber field
Hope this helps
Stephen