How do I add "autonumber" to an existing Access database

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

Guest

I created a database of about 400 records and for some reason there is no
"autonumber." How do I add this feature to this database...and don't you
need an identifier (like autonumber) in order to do a query? I don't know
much about this software and am limping along...so I greatly appreciate any
help I can get!
 
Right click on your table and select "Design View". Then, enter a new field
(i.e. call it AutoNumberVar). Then, select "AutoNumber" for Data Type.

No, you don't need an identifier to run a query, only if you will be linking
2 tables together in that query do you need one.
 
The autonumber won't be added to your table automatically. To add it, create
a field with datatype Autonumber in the table where your records are at. This
should automatically create autonumbers 1-400 for your records.

But, as a suggestion I would read up on databases and relationships before
going further. Google the topics, including normalization, as well as search
through these forums for other documentation. Sorry I don't have any helpful
links for you but there are plenty of posts here.

I hope this helps at least a little. :-)
 
carpqueen said:
I created a database of about 400 records and for some reason there
is no "autonumber." How do I add this feature to this database...and
don't you need an identifier (like autonumber) in order to do a
query? I don't know much about this software and am limping
along...so I greatly appreciate any help I can get!

You don't need an autonumber field ... unless you need one. Since it
seems you don't need one, (Is everything working OK?) then you don't need
one.
 
Thanks, Dave, for your help! When I do that (and I have done it over and
over), the order of the information is no longer alphabetical. The
information had been saved by last name and when I add the auto number field,
it re-orders it . What am I doing wrong? Also, maybe I don't even need this
field if I have the primary key as the last name and have it indexed (along
with others.) Why have autonumber ?

Thanks, again, for your help!
Lori
 
carpqueen said:
Thanks, Dave, for your help! When I do that (and I have done it over
and over), the order of the information is no longer alphabetical.
The information had been saved by last name and when I add the auto
number field, it re-orders it . What am I doing wrong? Also, maybe
I don't even need this field if I have the primary key as the last
name and have it indexed (along with others.) Why have autonumber ?

Access does not store data in nice list like Excel. Consider tables
like buckets with all the data dumped into them. If you don't specify an
order, you don't get an order. If you want it in alpha order then use a
sort on the report or form or specify the order in a query.

As for why have an autonumber, that is up to you. Autonumber is a way
of providing a unique number for each record. You only need this number if
you want to use it to link two tables. Access is a relational database so
it's real power is in relationships and autonumber helps setting up those
relationships when you don't have another unique field or combinations of
fields to use. Autonumber will not always remain in order.
 

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