日期:2014-05-17 浏览次数:20672 次
1 商品表
CREATE TABLE `wo_goods` (
`ID` BIGINT(20) NOT NULL AUTO_INCREMENT,
`goods_id` BIGINT(20) NOT NULL COMMENT '商品id',
`goods_content` VARCHAR(100) DEFAULT NULL COMMENT '商品描述',
`goods_price` DECIMAL(13,2) NOT NULL COMMENT '商品价格',
PRIMARY KEY (`id`)
) ENGINE=INNODB DEFAULT CHARSET=utf8 COMMENT='商品表'
2销售单表
CREATE TABLE `sale_ticket` (
`ID` BIGINT(20) NOT NULL AUTO_INCREMENT,
`st_id` BIGINT(20) NOT NULL COMMENT '销售单号',
`st_salerid` BIGINT(20) NOT NULL COMMENT '销售员id号',
PRIMARY KEY (`id`)
) ENGINE=INNODB DEFAULT CHARSET=utf8 COMMENT='销售单表'
CREATE TABLE `sale_goods` (
`ID` BIGINT(20) NOT NULL AUTO_INCREMENT,
`st_id` BIGINT(20) NOT NULL COMMENT '销售单id',
`goods_id` BIGINT(20) NOT NULL COMMENT '商品id',
`sg_number` BIGINT(20) NOT NULL COMMENT '商品数量',
PRIMARY KEY (`id`)
) ENGINE=INNODB DEFAULT CHARSET=utf8 COMMENT='销售单商品表'