当前位置:Gxlcms > PHP教程 > 新手的第一次mysql

新手的第一次mysql

时间:2021-07-01 10:21:17 帮助过:32人阅读

小弟看了那本《PHP和MySQL,Web开发》,今天刚看到数据库,照着代码抄了一份sql脚本,准备用PHPMyadmin上传,但是报错如下,查了一个多小时愣是没弄懂错在哪,求助各位大神指点迷津啊。。。
代码如下:
create table customers{	customerid int unsigned not null auto_increment primary key,	name char(50) not null,	address char(100) not null,	city char(30) not null};create table orders{	orderid int unsigned not null auto_increment primary key,	customerid int unsigned not null,	amout float(6,2),	date date not null};create table books{	isbn char(13) not null primary key,	author char(50),	title char(50),	price float(4,2)};create table order_items{	orderid int unsigned not null,	isbn char(13) not null,	quantity tinyint unsigned,	primary key(orderid,isbn)};create table book_reviews{	isbn char(13) not null primary key,	review text};


回复讨论(解决方案)

小弟自己找到原因了,原来是{}应该换成(),汗颜哪,到底电子书字太小了看不清,哈哈,抱歉。。。

人气教程排行