小弟最近学习网上的石大财务系统,在创建2各表格时
CREATE TABLE pay (
id int(11) NOT NULL auto_increment,
classid int(11) ,
payerid int(11) NOT NULL ,
paytypeid int(11) NOT NULL ,
money int(40) NOT NULL ,
project varchar(40) ,
message varchar(40) ,
addtime date NOT NULL ,
inout int(1) NOT NULL ,
PRIMARY KEY (id)
);
CREATE TABLE paytype (
id int(10) NOT NULL auto_increment,
name varchar(20) NOT NULL ,
inout int(1) NOT NULL ,
PRIMARY KEY (id),
KEY name (name)
);
出现如下问题:
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 'inout
int(2) NOT NULL ,
PRIMARY KEY (id)
)' at line 10ERROR 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 'inout
int(1) NOT NULL ,
PRIMARY KEY (id),
KEY name (name)
)' at line 4
我看了一下,好像没有什么语法错误,请各位看看,不胜感激!
CREATE TABLE pay (
id int(11) NOT NULL auto_increment,
classid int(11) ,
payerid int(11) NOT NULL ,
paytypeid int(11) NOT NULL ,
money int(40) NOT NULL ,
project varchar(40) ,
message varchar(40) ,
addtime date NOT NULL ,
inout int(1) NOT NULL ,
PRIMARY KEY (id)
);
CREATE TABLE paytype (
id int(10) NOT NULL auto_increment,
name varchar(20) NOT NULL ,
inout int(1) NOT NULL ,
PRIMARY KEY (id),
KEY name (name)
);
出现如下问题:
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 'inout
int(2) NOT NULL ,
PRIMARY KEY (id)
)' at line 10ERROR 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 'inout
int(1) NOT NULL ,
PRIMARY KEY (id),
KEY name (name)
)' at line 4
我看了一下,好像没有什么语法错误,请各位看看,不胜感激!
解决方案 »
免费领取超大流量手机卡,每月29元包185G流量+100分钟通话, 中国电信官方发货