Hi,

Its in the manual, but it is something like

ALTER TABLE Discharge ADD PRIMARY KEY (Vessel, Voyage, PortName);

Regards

Quentin

-----Original Message-----
From: Don [mailto:[EMAIL PROTECTED]]
Sent: Tuesday, 23 January 2001 10:39
To: msql list
Subject: Creating keys


The online documentation only has a syntax example of creating a key
consisting of a single column.  I wish to create a primary key
encompassing three columns.  Here is my syntax:

create primary key on Discharge (Vessel, Voyage, PortName);

where Discharge is my table name and all three fields names are not
null.  MySQL is reporting a syntax error.  What is the error please?

Thanks,
Don


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

The information contained in this email is privileged and confidential
and intended for the addressee only. If you are not the intended 
recipient, you are asked to respect that confidentiality and not 
disclose, copy or make use of its contents. If received in error 
you are asked to destroy this email and contact the sender immediately. 
Your assistance is appreciated.

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