mysql create table help with unique

Posted by Matt on Stack Overflow See other posts from Stack Overflow or by Matt
Published on 2010-05-27T02:41:17Z Indexed on 2010/05/27 2:41 UTC
Read the original article Hit count: 424

Filed under:
|
|

I'm trying to create a table, and can't figure out how to assign two columns to be unique.. I know how to alter a table thats already created, but how do you do it in the create..

im after a create if not exist col1 TEXT, col2 TEXT, col3 TEXT unique(col1, col2)

^very rough basic but you get the idea

© Stack Overflow or respective owner

Related posts about mysql

Related posts about unique