1.商品goods(商品编号goods_id,商品goods_name, 单价unitprice, 商品类别category, 供应商provider)
2.客户customer(客户号customer_id,姓名name,住址address,邮箱email,性别sex,身份证card_id)
3.购买purchase(购买订单号order_id,客户号customer_id,商品号goods_id,购买数量nums)
代码语言:javascript复制create table goods(
goods_id int,
goods_name varchar(50),
unit_price decimal(7,2),
category varchar(50),
provider varchar(50)
);
create table customer(
customer_id int,
name varchar(20),
address varchar(20),
sex varchar(5),
card_id varchar(18)
);
create table purches(
order_id int,
customer_id int,
goods_id int,
nums int
);
创建出来的表为