Key = Creates an index
Index = Same as above? (Not sure, the section of the manual I just glanced
at seems to indicate that they are the same thing)
PRIMARY KEY = Creates a primary key for the table.  Each table should have a
primary key and it should be unique for that row in that table. (For more on
PK theory, checkout
http://www1.fatbrain.com/asp/BookInfo/BookInfo.asp?theisbn=0764504150&from=T
GD352 )
UNIQUE = Like primary key in that it creates a unique index on that field
but it is not considered a primary key.

Cal
http://www.calevans.com


-----Original Message-----
From: Duke [mailto:[EMAIL PROTECTED]]
Sent: Tuesday, March 27, 2001 8:59 AM
To: [EMAIL PROTECTED]
Subject: keywords in CREATE TABLE?


what are the basic differences in the CREATE TABLE command for the following
keywords?
I checked the MySQL manual but couldnt make much sense outa it.
KEY
INDEX
PRIMARY KEY
UNIQUE

plz. could anyone ellaborate more on UNIQUE AND PRIMARY KEY.? it seems that
both are doing the same job?...



duke.

Website: http://www.ilug-bom.org.in/
Ftp site: ftp.ilug-bom.org.in
Chat: irc.ilug-bom.org.in
Linuxers mailing list: [EMAIL PROTECTED]
http://ilug-bom.org.in/mailman/listinfo/linuxers


____________________________________________________________________
Get free email and a permanent address at http://www.netaddress.com/?N=1

---------------------------------------------------------------------
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