注册 登录
编程论坛 MySQL论坛

mysql 中创建表

yanzi啊 发布于 2010-11-28 11:02, 709 次点击
在mysql中创建一个表t
create table 't'('id' varchar(10) not null)
会提示错误
 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' varchar(10) not null)' at line 1
该怎么解决??
4 回复
#2
rabbit_1232010-12-07 11:49
不是单引号 ',而是 `
运行下面的就对了:
create table `t`(`id` varchar(10) not null)
#3
zhoufeng19882010-12-08 13:07
Tab上面的那个键。
#4
jianghong_022010-12-08 18:38
在mysql中创建一个表t
create table t
(id varchar(10) not null)
#5
leo762011-03-30 17:08
慢慢来吧,兄弟。
1