can I reuse deleted numbers in a primary key ID# field in Access?

  • Thread starter Thread starter Guest
  • Start date Start date
G

Guest

In my Access database I have had to delete about 20 records. I would like to
somehow reuse those numbers as I have photo files linked to the primary key
ID# that is automatically generated by Access.

Anyone who has an idea how to do this?

thnx
 
No, autonumbers are intended to be "unique", and, except for a defect or two
over the years (now apparently corrected) not consecutive. They just hapen
to be consecutive in their simplest form, most of the time, if nothing
unusual happens.
 
diecastnut_1916 said:
In my Access database I have had to delete about 20 records. I would
like to somehow reuse those numbers as I have photo files linked to
the primary key ID# that is automatically generated by Access.

Anyone who has an idea how to do this?

thnx

I suggest you may not want to use Autonumber for that use. Autonumbers are
designed to provide unique numbers. It in not designed to provide numbers
in order and for a number of reasons may not do so. As a result using them
in any application where the user sees the numbers is likely to end up with
confusion.

There are other ways of providing the numbers you want depending on the
particual application.

Note: If you compact the database, Access MAY reuse those numbers, then
again it may not, you never know and you should not care.
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Back
Top