Resetting Autonumbers and creating new rows

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

Guest

Hi, I have a table which starts with an autonumber as the primary key.

Two things I am having difficulty with. I've noticed if I were to create
seven items on the row, the autonumber would go up to seven, delete the last
three, the next number would be eight. Is there anyway to make it so it
reuses numbers once they are no longer represented on the table rather then
continously counting up?

Second, I want to add rows to a table (the same one actually) where all the
fields are blank, instead of changing the rows, I want to do this with a
query, I assume I need to do it using an append query, but I do not know how.
The rows would ideally be blank, but I could start with just one field,
aside from the autonumber field. Thanks.
 
UnderSeven said:
Hi, I have a table which starts with an autonumber as the primary key.

Two things I am having difficulty with. I've noticed if I were to
create seven items on the row, the autonumber would go up to seven,
delete the last three, the next number would be eight. Is there
anyway to make it so it reuses numbers once they are no longer
represented on the table rather then continously counting up?

Second, I want to add rows to a table (the same one actually) where
all the fields are blank, instead of changing the rows, I want to do
this with a query, I assume I need to do it using an append query,
but I do not know how. The rows would ideally be blank, but I could
start with just one field, aside from the autonumber field. 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.

See:
http://www.lebans.com/rownumber.htm
 
Back
Top