Autonumbers

  • Thread starter Thread starter Asif
  • Start date Start date
A

Asif

I have a form with some data being displayed when I go to update the
form an update query runs asking I'm about to update 1 row and I click
yes. The Autonumber (ID field) displayed in this form changes but not
from say 1 to 2 but rather it jumps from 1 to 3. Any ideas why this is
happening?

Thanks
 
Asif said:
I have a form with some data being displayed when I go to update the
form an update query runs asking I'm about to update 1 row and I click
yes. The Autonumber (ID field) displayed in this form changes but not
from say 1 to 2 but rather it jumps from 1 to 3. Any ideas why this is
happening?

Thanks

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.
 
The reason for the jumps is as follows. Create a new record
(Autonumber = 1) If you "dirty" (write something into a field) a form
Access assigns the next Autonumber to that record (Autonumber = 2) and
it's gone. If you cancel that new record and then dirty it you get a
new autonumber (Autonumber = 3).

Cheers,
Jason Lepack
 
Back
Top