View Single Post

  #1 (permalink)  
Old 04-19-2007
JH
 
Posts: n/a
Default Alter a combination of 2 existing columns as a unique key

To alter 1 column to a unique key, for example,

ALTER TABLE user MODIFY COLUMN id INT NOT NULL UNIQUE;

But how to set a combination of 2 columns as a unique key?
Individual keys are not unique, but combination is.


TIA,
James

Reply With Quote