If this is your first visit, be sure to check out the FAQ by clicking the link above. You may have to register before you can post: click the register link above to proceed. To start viewing messages, select the forum that you want to visit from the selection below. |
|
|
Thread Tools | Display Modes |
#11
|
|||
|
|||
New Database - Primary Key
On Mon, 8 Jun 2009 16:00:05 +0100, Bernard Peek
wrote: Hi Bernard, If you add an autonumber field you would call it a surrogate key. Yes, an AutoNumber can act as a surrogate key with automatically generated values. But Access refers to an autonumber field as a primary key, which I consider to be a serious flaw in its design. Not really. Access supports a table having a primary key, which is a field (or combination of fields) that uniquely identifies each record. And Access supports an AutoNumber datatype, which is a Long Integer assigned unique values automatically. However, you do not *have* to make it the primary key, although that's normally how it's used. You can have one field (or fields) as a primary key, and another non-PK AutoNumber field. So they are *not* the same thing, and Access doesn't refer to them as such. Access will offer to create a PK using an AutoNumber if you try to save a table without a PK, but that's just it trying to help. It doesn't claim that they're the same thing. So Access does not have the "serious flaw" you're referring to. Armen Stein Microsoft Access MVP www.JStreetTech.com |
Thread Tools | |
Display Modes | |
|
|