It's ok for a table to have 2 keys that COULD be the PIKE.  only 1 of them
can actually BE the PIKE, the other is a Candidate Key. (CK)

As to whether you should make them both part of the PK, that's a different
question.  I usually avoid compound PK's unless there is NO OTHER WAY AROUND
IT.

Cal
http://www.calevans.com


-----Original Message-----
From: John Halladay [mailto:[EMAIL PROTECTED]]
Sent: Tuesday, February 06, 2001 2:36 PM
To: MySQL List (E-mail)
Subject: PK, SK, FK . . . ?


Terribly simple question, but I'm fairly new at this.

I'm building a database based off a model built in MS Access.  The table
that I'm currently working on appears to have two Primary Keys, although I'm
assuming one of them must be secondary.  How would I specify this in
creating the table in MySQL?  Would I need to create a composite key, etc.?

Thanks.

John Halladay
BISYS - Commission Accounting
Phone: 801.532.6660 x7973
Fax: 801.533.7879
www.ascensus.com
Life   LTC   Annuities   Variable   Disability


---------------------------------------------------------------------
Before posting, please check:
   http://www.mysql.com/manual.php   (the manual)
   http://lists.mysql.com/           (the list archive)

To request this thread, e-mail <[EMAIL PROTECTED]>
To unsubscribe, e-mail <[EMAIL PROTECTED]>
Trouble unsubscribing? Try: http://lists.mysql.com/php/unsubscribe.php



---------------------------------------------------------------------
Before posting, please check:
   http://www.mysql.com/manual.php   (the manual)
   http://lists.mysql.com/           (the list archive)

To request this thread, e-mail <[EMAIL PROTECTED]>
To unsubscribe, e-mail <[EMAIL PROTECTED]>
Trouble unsubscribing? Try: http://lists.mysql.com/php/unsubscribe.php

Reply via email to