日期:2014-05-16  浏览次数:20789 次

MYSQL 自动增加错了
mysql> create table c(id int primary key identity(1,1));
ERROR 1064 (42000): 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 'ident
ity(1,1))' at line 1


create table c(id int primary key identity(1,1)); 哪里写错了? 

谢谢大家帮忙

------解决方案--------------------
MySQL 中没有 identity(1,1));

是auto_increment
SQL code
create table c(id int primary key auto_increment);