Re: AutoNumber Question
- From: "tina" <nospam@xxxxxxxxxxx>
- Date: Wed, 26 Apr 2006 04:17:50 GMT
again, i quite agree. even in cases where no natural key is available in a
table, Autonumber is not the only alternative, and certainly not the best
alternative in *every* situation.
"BruceM" <bamoob@xxxxxxxxxxxxxxxxxx> wrote in message
news:e4potKGaGHA.4424@xxxxxxxxxxxxxxxxxxxxxxx
Hi Tina,be
I could have made it clearer that I was responding specifically to the
following:
"If it were a Database containing vehicle information, the VIN would not
a proper number to use a primary key identifier either (just like a SSN),identify
but instead a value relating to another value. And even then, a random
number, such as Access' AutoNumber should be used for the system to
it and its uniqueness."such
I just wanted to point out that there is no need to get stuck on using
a number. To say that something such as as autonumber *should* be used asto
the PK is to create a rule where one is not needed.
"tina" <nospam@xxxxxxxxxxx> wrote in message
news:F%e3g.39457$az4.38385@xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx
you're quite right, Bruce - a primary key does not need to meaningless
*Autonumber*the user. in this thread we were discussing specifically the
alsoas
primary key, so the posted comments were applicable. i agree with you
keythat a unique value is not necessarily a good candidate for a natural
bein
a table; that decision should be made on a table by table basis in every
relational data model, based on a number of factors that may or may not
numberunique to that business process.
"BruceM" <bamoob@xxxxxxxxxxxxxxxxxx> wrote in message
news:eGeGJA6ZGHA.3972@xxxxxxxxxxxxxxxxxxxxxxx
I would like to point out that a primary key does not need to bemeaningless
to the user. A sequential number such as 000001, 000002, etc. may be
used
for invoice numbers or the like. I don't see any reason why that
acan't be the PK.would
There are legal reasons why SSN should not be widely available in a
database, as it would be if it was part of relationships. However, I
think an employer would want to know if the number is not unique. IfJohn
John
Smith leaves the company, and five years later Jill Jones shows up with
Smith's SSN, I expect it would be a real mess for a company that simplya
ignores the duplication.
A VIN as a PK could get a bit murky for an insurance company or the DMV
if
vehicle changes hands, but I expect either entity would want to know if
situations.VIN is being reused. A VIN could make sense as a PK in some
ThereUniqueness is one thing; suitablility for use as a PK is another.
eitherare
a lot of possible circumstances, each of which needs to be consideredimportant
separately.
"accessquestions" <vinootz@xxxxxxxxxxx> wrote in message
news:eSewKFzZGHA.3304@xxxxxxxxxxxxxxxxxxxxxxx
understood. I actually thought of that after I posted.
Just goes to show that it really takes an analytical mind to perfect
the
concepts of relational databases.
A VIN, like you state, serves a purpose, and is an attribute (an
theone) of a vehicle. Not just a random number to identify it's
uniqueness
in a database. If it were a Database containing vehicle information,
VIN would not be a proper number to use a primary key identifier
And(just like a SSN), but instead a value relating to another value.
haveforeven then, a random number, such as Aceess' AutoNumber should be used
the system to identify it and its uniqueness.
This dialogue was very educational for me as it relates to what I
other"determineread many times on the boards :put it all on paper first", and,
all information to be stored in the database and its relations to
thetables" before creating them. If this was done, I would know that
Identifier.SSN
and VIN Numbers were not suitable candidates for a Unique
notPoint Taken !
Thanks for all your insight ,as usual
VL
"tina" <nospam@xxxxxxxxxxx> wrote in message
news:DcS2g.35670$az4.17951@xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx
well, glad i could help. :)
but i have to point out that the VIN analogy is not apt. a VIN is
maximumsometimesjust a
collections of numbers/letters, it is a very specific code that
identifies
manufacturer, make and model of vehicle, model year of vehicle,
where the vehicle was built, sometimes engine size, sometimes
digitspayload for trucks, and other data - as well as the last 4 to 6
database,fromthat
are unique to a specific vehicle that is otherwise identical to many
other
vehicles in all those other respects. so a VIN has meaning separate
any
tracking database that stores it, and it must often be seen and used
directly by people - such as manufacturers, owners, insurers, DMVs.
an Autonumber primary key, on the other hand, has no meaning outside
of
the
database where the data is stored, and no meaning within the
maytheexcept to the software - and it absolutely should *not* be used with
idea of attaching a meaning to it. it also should not be seen by
anyone
who
uses the database, at any time - excepting only that the developer
autoit,look
at Autonumber values from time to time while building and/or
troubleshooting
the database.
hth
"accessquestions" <vinootz@xxxxxxxxxxx> wrote in message
news:exGDWOwZGHA.608@xxxxxxxxxxxxxxxxxxxxxxx
good point.
the Auto Number is sort like a VIN on a car, you rarely have to see
memory,but
its there and its serving a purpose,, and nobody committs it to
if
they would it would just confuse them. you convinced me, im an
creditagain,number
guy from now on.reasons.
thanks
"tina" <nospam@xxxxxxxxxxx> wrote in message
news:PAP2g.35270$az4.14873@xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx
well, personally, i would not use the SSN as a primary key, for 2
duplicatesfirst, SSNs are unfortunately not unique; there are many, many
specificfloating around out there. of course, only one person is using a
SSN *legally*, but unless you want to get into tracking down
fraudulent
use... second, if you use the SSN as primary key, you'll have it
populating
multiple tables, potentially scattered all over your database.
personally, i would safeguard an SSN the same way i would a
socard
number, in my database; put it in one place, and one place only,
Autonumberit's
easier to protect by whatever means you use to secure proprietary
data.
having said all that, there's no reason you can't use an
valueas
the
primary key field for your employee table *as long as it is a
usetablethe
has
no meaning to anyone, only to Access*. your user should never see
an
Autonumber primary key, or use it directly to search for a record
in
the
table. don't confuse how your *user* finds a certain record in a
with
how *Access* identifies each record in a table. you can easily
an
employeeAutonumber primary key and still allow your user to seach for an
record using the person's SSN.
hth
"accessquestions" <vinootz@xxxxxxxxxxx> wrote in message
news:uhOmL0vZGHA.3652@xxxxxxxxxxxxxxxxxxxxxxx
Hello,feature,
As far as a Primary Key is concerned (for an Employee Table)
I have read numerous times on the boards NOT to use the Auto
Number
I'm not sure exactly why, although I could see where the randomcan
number
confuse some.will
Would anyone recommend using a SSN instead? It will be unique,
and
it
serve as a good reference to the employee.
Any thoughts of why or why not?
Thanks Again !
VL
.
- References:
- AutoNumber Question
- From: accessquestions
- Re: AutoNumber Question
- From: tina
- Re: AutoNumber Question
- From: accessquestions
- Re: AutoNumber Question
- From: tina
- Re: AutoNumber Question
- From: accessquestions
- Re: AutoNumber Question
- From: BruceM
- Re: AutoNumber Question
- From: tina
- Re: AutoNumber Question
- From: BruceM
- AutoNumber Question
- Prev by Date: Newbie Design question re: how many tables
- Next by Date: Re: Copying and Pasting from one table to another
- Previous by thread: Re: AutoNumber Question
- Next by thread: Re: AutoNumber Question
- Index(es):
Relevant Pages
|
Loading