我正在尝试创建一个表。我认为表格的规格从我正在运行的命令中应该很明显:
create table users{
id mediumint unsigned not null auto_increment,
username varchar(40) not null,
sprinkles bigint unsigned not null,
passhash binary(64) not null,
passsalt binary(64) not null,
x decimal(10,1),
y decimal(10,1),
primary key (id),
unique key idx_unique_username (username)
} engine = INNODB DEFAULT character set = utf8 COLLATE = utf8_general_ci;
但是,当我尝试将其输入 MySQL 时,它给了我这个错误:
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 '{
id mediumint unsigned not null auto_increment,
username varchar(40) not null,
' at line 1
我的mysql版本是Ver 14.14 Distrib 5.5.31, for debian-linux-gnu (x86_64) using readline 6.2