something other that AutoNumber

  • Thread starter Thread starter Ryan Young
  • Start date Start date
R

Ryan Young

I have a table set up in which I have added a new field. Ideally, I would
have liked this set to AutoNumber but I can't do that in an existing table.
Is there a way to set something up in that column that would work similarly?
Even if I could get it to refer to the actual record number, that would work
too. Any help is appreciated!
 
I have a table set up in which I have added a new field. Ideally, I would
have liked this set to AutoNumber but I can't do that in an existing table.
Is there a way to set something up in that column that would work similarly?
Even if I could get it to refer to the actual record number, that would work
too. Any help is appreciated!

Well, since tables don't HAVE record numbers, what you ask last is not
possible.

What will you use this field for? What's the current Primary Key of
the table (or does it lack one)? Do you intend this to be a
user-visible number? What values do you want inserted into existing
records?

John W. Vinson[MVP]
 
Provided that you haven't got an existing AutoNumber Field in the Table, you
can add an AutoNumber Filed to the Table.

There is absolutely no reason to have 2 AutoNumber Fields in a Table.
Hence, Access / JET doesn't allow 2 AutoNumber Fields in a Table.

There is no (hidden) Record Number in Access Table AFAIK.

HTH
Van T. Dinh
MVP (Access)
 
John,

Right you are, I guess I was looking that the bottom of my form which says I
am on record x of y records.

Anyhow, the primary key in this table it ID. The field I want to have the
numbers in is Orders, which is an order number assigned as orders come in.
This field is then sorted in my reports so that all records in the table are
displayed in the order in which they were entered (as I learned earlier that
Access doesn't do this itself - they were random). The Order field is not
shown in any reports - only used behind the scenes for sorting. The value
entered in the cell is always the value of the record prior plus 1.

But now the more I learn more about Access, I realise that what I should do
is add the ID field (the primary key) to the query and simply have it sort
by that. Makes sense, right?
 
John,

Right you are, I guess I was looking that the bottom of my form which says I
am on record x of y records.

That's a temporary and dynamic number. If you filter or re-sort the
form, the numbers will change; the number you see has no permanent
connection to the data in the record you're looking at.
Anyhow, the primary key in this table it ID.

And what's its datatype? Autonumber, sequential?
The field I want to have the
numbers in is Orders, which is an order number assigned as orders come in.
This field is then sorted in my reports so that all records in the table are
displayed in the order in which they were entered (as I learned earlier that
Access doesn't do this itself - they were random). The Order field is not
shown in any reports - only used behind the scenes for sorting. The value
entered in the cell is always the value of the record prior plus 1.

But now the more I learn more about Access, I realise that what I should do
is add the ID field (the primary key) to the query and simply have it sort
by that. Makes sense, right?

If it's sequential and ascending, by all means!

John W. Vinson[MVP]
 

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