0
CREATE TABLE tblUser 
( 

    CREATE UNIQUE INDEX i_ITUsername ON tblUser (ITUsername),
    CREATE UNIQUE INDEX i_email ON tblUser (email),
    CREATE INDEX i_disability ON tblUser (disability),
    CREATE INDEX i_name ON tblUser (name)
) TYPE = MyISAM; 

谁能明白为什么我在第一个唯一索引行出现错误?据我所知,没有错误:(

4

1 回答 1

1

第一个错误是您在一列上有两种数据类型,

mobilePhone long int UNSIGNED not null, -- choose one INT or LONG
housePhone long int UNSIGNED,

第二个是你声明喜欢TSQL,这里是 mysql,

primary key (ITUsername),
UNIQUE i_ITUsername  (ITUsername),
UNIQUE i_email (email),
KEY i_disability  (disability),
KEY i_name (name)
于 2013-03-13T09:30:46.107 回答