1
ALTER TABLE  `The Watch Desk Articles Index` ADD  `Subject` VARCHAR CHARACTER SET utf8                 
COLLATE utf8_general_mysql500_ci NOT NULL AFTER `none` ,
ADD FULLTEXT (

`Subject`
)


#1064 - You have an error in your SQL syntax; check the manual that corresponds to your   
MySQL server version for the right syntax to use near 'CHARACTER SET utf8 COLLATE  
utf8_general_mysql500_ci NOT NULL AFTER `none`,  ADD ' at line 1 

这个错误要求我改变什么?我正在使用 phpMyAdmin 构建带有选择框的表格列,但我一直收到此错误。

4

1 回答 1

1

至少,您必须指定 varchar 字段的大小,例如最多允许 255 个字符:

 ALTER TABLE  `The Watch Desk Articles Index` ADD  `Subject` VARCHAR(255) 
     CHARACTER SET  ...rest of stuff here...
于 2012-11-28T21:27:38.363 回答