I want to set primary keys of letters plus Autonumbers

G

Guest

I would like to have unique identifiers for each table. The Access Autonumber
is rather unfriendly. Would it be possible to take the letters of the
tablename + a surname, or the initials of a name, or any other set of letters
and add an Autonumber to it?
i.e. tablename_surname_AutoNumber
I am struggling with how to make each table's primary Key obviously unique
to that table instead of many tables each having 01,02, 03 etc. As I have
(among 15 tables so far) 4 tables with names and addresses in them, simple
AutoNumbers could be confusing.
 
D

Douglas J. Steele

You can have up to 10 fields in a single index that makes up the Primary
Key. However, what difference does it make? It's rare that you even show the
value of the Autonumber field to the users.
 
T

Tim Ferguson

I am struggling with how to make each table's primary Key obviously
unique to that table instead of many tables each having 01,02, 03 etc.

But there is no reason anywhere on earth where that would be a useful or a
sensible thing to do. There is no commonality between two different
entities (otherwise they'd be the same entity and in the same table...), so
there is no chance of overlap.
As I have (among 15 tables so far) 4 tables with names and addresses
in them, simple AutoNumbers could be confusing.

If they are addresses for the same things, then they need to be in the same
table. If they are addresses for different things then it doesn't matter
what the ID numbers look like.

This is a problem looking for a business case, I'm afraid.


Tim F
 

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

Top