加入 Gitee
与超过 1200万 开发者一起发现、参与优秀开源项目,私有仓库也完全免费 :)
免费加入
文件
该仓库未声明开源许可证文件(LICENSE),使用请关注具体项目描述及其代码上游依赖。
克隆/下载
electronic_sale.sql 22.78 KB
一键复制 编辑 原始数据 按行查看 历史
MJnightingale 提交于 2017-04-20 15:28 . 引入一些css
/*
Navicat MySQL Data Transfer
Source Server : localhost
Source Server Version : 50711
Source Host : localhost:3306
Source Database : electronic_sale
Target Server Type : MYSQL
Target Server Version : 50711
File Encoding : 65001
Date: 2017-04-20 15:24:50
*/
SET FOREIGN_KEY_CHECKS=0;
-- ----------------------------
-- Table structure for admin
-- ----------------------------
DROP TABLE IF EXISTS `admin`;
CREATE TABLE `admin` (
`admin_id` int(11) NOT NULL,
`admin_name` varchar(12) DEFAULT NULL,
`admin_password` varchar(20) DEFAULT NULL,
PRIMARY KEY (`admin_id`)
) ENGINE=InnoDB DEFAULT CHARSET=utf8;
-- ----------------------------
-- Records of admin
-- ----------------------------
INSERT INTO `admin` VALUES ('1', 'admin@qq.com', '7758234');
-- ----------------------------
-- Table structure for customer
-- ----------------------------
DROP TABLE IF EXISTS `customer`;
CREATE TABLE `customer` (
`customer_id` int(11) NOT NULL AUTO_INCREMENT COMMENT '系统生成id',
`customer_name` varchar(20) DEFAULT NULL COMMENT '昵称',
`customer_presonal_id` varchar(20) DEFAULT NULL COMMENT '账户名(废弃不用)',
`customer_real_name` varchar(6) DEFAULT NULL COMMENT '姓名(废弃不用)',
`customer_password` varchar(100) DEFAULT NULL,
`customer_sex` varchar(2) DEFAULT NULL,
`customer_birthday` date DEFAULT NULL COMMENT '注册日期',
`customer_phone` varchar(15) DEFAULT NULL,
`customer_email` varchar(50) DEFAULT NULL,
`customer_address` varchar(255) DEFAULT NULL,
`customer_extea_message` varchar(1000) DEFAULT NULL,
PRIMARY KEY (`customer_id`)
) ENGINE=InnoDB AUTO_INCREMENT=29 DEFAULT CHARSET=utf8;
-- ----------------------------
-- Records of customer
-- ----------------------------
INSERT INTO `customer` VALUES ('1', 'aa', 'aa', 'aaa', 'aa,aa', null, '2016-12-07', 'aa', 'a', null, null);
INSERT INTO `customer` VALUES ('2', 'haha', '123445', null, '12345,1234', 'on', '2016-12-10', null, '654183947@163.com', null, null);
INSERT INTO `customer` VALUES ('3', '2343242', '1232', null, '342342342', '男', '2016-12-10', null, '32432@qq.com', null, null);
INSERT INTO `customer` VALUES ('7', 'longda', null, null, '12334', '男', '2016-12-10', '1233445', '654183947@163.com', null, null);
INSERT INTO `customer` VALUES ('11', 'longda', null, null, '7758234', '男', '2016-12-10', '18813752768', '654183947@163.Com', null, null);
INSERT INTO `customer` VALUES ('12', 'longdan', null, null, '7758234', '男', '2016-12-12', '18813752768', '654183947@qq.com', null, null);
INSERT INTO `customer` VALUES ('13', 'long', null, null, '7758234', '男', '2016-12-12', '18813752766', '654183947@162.com', null, null);
INSERT INTO `customer` VALUES ('14', 'long', null, null, '7758234', '男', '2016-12-12', '18813752766', '654183947@161.com', null, null);
INSERT INTO `customer` VALUES ('15', 'longda1', null, null, '7758234', '男', '2016-12-12', '13234443233', '645183947@qq.com', null, null);
INSERT INTO `customer` VALUES ('16', 'longda1', null, null, '7758234', '男', '2016-12-12', '13234443233', '645183147@qq.com', null, null);
INSERT INTO `customer` VALUES ('17', '明俊', null, null, '7758234', '男', '2016-12-13', '7758234', '654183957@qq.com', null, null);
INSERT INTO `customer` VALUES ('18', 'btai', null, null, '123456', '男', '2017-03-06', '188188188188', '6546546546@shasha.com', null, null);
INSERT INTO `customer` VALUES ('19', 'nihao', null, null, 'asdf', '男', '2017-03-06', 'hahaha', 'shash@qq.com', null, null);
INSERT INTO `customer` VALUES ('20', 'yong', null, null, '123', '男', '2017-03-06', '23432435', 'ahaha@qq.com', null, null);
INSERT INTO `customer` VALUES ('21', '6chenmingjun', null, null, '7758234', '男', '2017-03-13', '18813752768', '6chenmingjun@qq.com', null, null);
INSERT INTO `customer` VALUES ('22', '7chenmingjun', null, null, '7758234', '男', '2017-03-13', '18813752768', '7chenmingjun@qq.com', null, null);
INSERT INTO `customer` VALUES ('23', '8chenmingjun', null, null, '123456', '男', '2017-03-13', '18813752768', '8chenmingjun@qq.com', null, null);
INSERT INTO `customer` VALUES ('24', '9chenmingjun', null, null, '123456', '男', '2017-03-13', '18813752768', '9chenmingjun@qq.com', null, null);
INSERT INTO `customer` VALUES ('25', '9chenmingjun', null, null, '1234', '男', '2017-03-13', '18813752768', '9chenmingjun@qq.com', null, null);
INSERT INTO `customer` VALUES ('26', '10chenmingjun', null, null, '123456', '男', '2017-03-13', '18813752768', '10chenmingjun@qq.com', null, null);
INSERT INTO `customer` VALUES ('27', '0314家里测试', null, null, '123', '男', '2017-03-14', '123', 'test@qq.com', null, null);
INSERT INTO `customer` VALUES ('28', '测试企业', null, null, '7758234', '男', '2017-04-02', '1233445', 'ewrw@qq.com', null, null);
-- ----------------------------
-- Table structure for goods
-- ----------------------------
DROP TABLE IF EXISTS `goods`;
CREATE TABLE `goods` (
`goods_id` int(11) NOT NULL AUTO_INCREMENT COMMENT '商品id',
`goods_brand` varchar(20) DEFAULT NULL COMMENT '品牌名',
`goods_name` varchar(20) DEFAULT NULL COMMENT '商品名',
`goods_type` varchar(11) DEFAULT NULL,
`goods_description` varchar(1000) DEFAULT NULL,
`goods_price` int(11) DEFAULT NULL,
`goods_production_date` date DEFAULT NULL COMMENT '原产品生产时间,废弃',
`goods_number` int(11) DEFAULT NULL,
PRIMARY KEY (`goods_id`),
KEY `type_id` (`goods_type`)
) ENGINE=InnoDB AUTO_INCREMENT=42 DEFAULT CHARSET=utf8;
-- ----------------------------
-- Records of goods
-- ----------------------------
INSERT INTO `goods` VALUES ('18', '联想', '拯救者', '笔记本', 'ISK15.6英寸游戏笔记本电脑(i5-6300HQ 8G 1T HDD GTX960M 4G独显 FHD IPS屏 )黑', '5299', null, '22');
INSERT INTO `goods` VALUES ('20', '联想', '小新700', '笔记本', '电竞尊享升级版15.6英寸游戏笔记本电脑(i5-6300HQ 8G )', '4999', null, '43');
INSERT INTO `goods` VALUES ('21', '惠普', '暗夜精灵2', '笔记本', '15.6英寸游戏笔记本(i5-6300HQ 4G 128SSD+1T', '4999', null, '98');
INSERT INTO `goods` VALUES ('22', '华硕', '顽石四代尊享版', '游戏本', '15.6英寸笔记本电脑(i7-7500U 8G 1TB NV940MX', '6999', null, '11');
INSERT INTO `goods` VALUES ('25', '戴尔', '雷神', '游戏本', '911-S1g 15.6英寸游戏笔记本电脑(i7-6700HQ 8G 128G+1T GTX1060 6G Windows 背光 IPS)', '7999', null, '89');
INSERT INTO `goods` VALUES ('26', '联想', '杨天M3900c', '台式机', '台式电脑( E1-7010 4G 500G 集成显卡 千兆网卡', '2049', null, '12');
INSERT INTO `goods` VALUES ('27', '联想', 'IdeaCentre C560', '一体机', '23英寸一体机电脑(i5-4460T 8G 1T 2G独显', '5299', null, '45');
INSERT INTO `goods` VALUES ('28', '联想', 'IdeaCentre C561', '一体机', '23英寸一体机电脑(i5-4460T 8G 1T 2G独显 Rambo刻录 Wifi Win10)黑色', '5499', null, '74');
INSERT INTO `goods` VALUES ('29', '联想', '致美一体机AIO 510S', '一体机', '23英寸一体机台式电脑( I5-6200U 8G 1T GT930A 2G显卡 win10)银', '6299', null, '65');
INSERT INTO `goods` VALUES ('30', '戴尔', '成就Vostro 3800-R6308', '台式机', '台式电脑(i3-4170 4G 500G DVD 三年上门 三年硬盘保留)19.5英寸', '2999', null, '87');
INSERT INTO `goods` VALUES ('31', '联想', 'H3060', '台式机', '台式电脑(I3-6100 4G 500G DVD 无线网卡 蓝牙 三年上门 Win10)21.5英寸\r\n【显示器升21.5英寸!第六代CPU i3-6100!】升级大屏比19.5/20英寸更适合商务', '3999', null, '64');
INSERT INTO `goods` VALUES ('32', '联想', 'Inspiron3650-R5838', '台式机', '灵越台式电脑(i5-6400 8GB 1TB 2G独显 DVD WIFI 蓝牙 三年上门 Win10)23英寸 搭载戴尔23英寸IPS全尺寸高清大屏,大屏幕让你显示更悦目', '4999', null, '44');
INSERT INTO `goods` VALUES ('33', '华硕', '如意V221ID', '一体机', '家用商务办公游戏台式一体机电脑 21.5英寸全高清四核 深海黑1TB版\r\n【年货节高潮期】领券优惠购!新品节能型一体机,前置双立体声音响,送办公四件套', '3299', null, '33');
INSERT INTO `goods` VALUES ('34', '华硕', 'Z240ICGK-GC041X', '一体机', '23.8英寸全高清傲世一体机办公游戏电脑 I5潮流版【盛世美颜,傲世君临】全高清IPS屏,杜比音效,畅享视听盛宴。', '5499', null, '34');
INSERT INTO `goods` VALUES ('35', '华硕', '如意V221ID', '一体机', '家用商务办公游戏台式一体机电脑 21.5英寸全高清四核 群星白1TB版\r\n【年货节高潮期】领券优惠购!新品节能型一体机,前置双立体声音响,送办公四件套', '3209', null, '56');
INSERT INTO `goods` VALUES ('36', '惠普', '畅游人Pavilion', '笔记本', '14-al125TX 14英寸轻薄笔记本(i5-7200U 8G 256GSSD 940MX 2G独显 FHD IPS)银色\r\n【打白条12期免息】20mm不到的轻薄机身!A面金属!第七代处理器!高性能独显!', '4299', null, '224');
INSERT INTO `goods` VALUES ('37', '惠普', 'Spectre x360', '笔记本', '13-w021TU 13.3英寸超轻薄翻转笔记本(i5-7200U 8G 256G SSD FHD 触控屏 )银色\r\n【打白条12期0首付0利息,一期667元不到带回家】真超薄!窄边框!360°翻转!触控屏!全金属!', '7999', null, null);
INSERT INTO `goods` VALUES ('38', '惠普', '畅游人Pavilion x360', '笔记本', '13-u115TU 13.3英寸超薄360°笔记本(i5-7200U 4G 128GSSD IPS FHD 触控屏)金色\r\n第七代CPU新品降临!肖奈同款笔记本,值得拥有!360°翻转,IPS高清屏!', '4499', null, '76');
INSERT INTO `goods` VALUES ('39', '联想', '拯救者2代', '游戏本', '15.6英寸游戏笔记本电脑(i7-6700HQ 8G 1T HDD GTX960M 4G独显 FHD IPS 背光)黑 【预装价值749元正版office!4G显存升级来袭!】游戏本就选联想拯救者!强大性能炫酷外形!', '5999', null, '45');
INSERT INTO `goods` VALUES ('40', '华硕', '战神K610D-i7D4', '游戏本', '15.6英寸游戏本笔记本电脑(i7-4710MQ 4G 500G GT940M 2G独显 1080P)灰色\r\ni7标压绝不拖泥带水!GT940M给你更高的视觉体验!别说话,开黑拿五杀!', '3899', null, '34');
INSERT INTO `goods` VALUES ('41', '华硕', 'GE62 6QD-1077XCN', '游戏本', '15.6英寸游戏笔记本电脑(i7-6700HQ 8G 1T GTX960M GDDR5 多彩背光)黑\r\n经典模具,微星490兄弟款爆品推荐,多彩背光键盘更炫', '6599', null, '87');
-- ----------------------------
-- Table structure for goods_upload
-- ----------------------------
DROP TABLE IF EXISTS `goods_upload`;
CREATE TABLE `goods_upload` (
`upload_id` int(6) NOT NULL AUTO_INCREMENT,
`goods_id` int(6) DEFAULT NULL,
`upload_location` varchar(100) DEFAULT NULL,
`upload_name` varchar(50) DEFAULT NULL,
`upload_time` date DEFAULT NULL COMMENT '上传时间,自动生产',
`upload_type` varchar(20) DEFAULT NULL COMMENT '图片类型',
PRIMARY KEY (`upload_id`),
KEY `goods_id` (`goods_id`),
CONSTRAINT `goods_id` FOREIGN KEY (`goods_id`) REFERENCES `goods` (`goods_id`) ON DELETE CASCADE ON UPDATE CASCADE
) ENGINE=InnoDB AUTO_INCREMENT=36 DEFAULT CHARSET=utf8;
-- ----------------------------
-- Records of goods_upload
-- ----------------------------
INSERT INTO `goods_upload` VALUES ('12', '18', '/electronic_sale/uploads/2017/01/11/', 'be83fb71-f2bb-434f-a3c0-7e040c0bf5e8.jpg', '2017-01-11', 'image/jpeg');
INSERT INTO `goods_upload` VALUES ('14', '20', '/electronic_sale/uploads/2017/01/11/', '794cfb99-11ed-4c9a-8b59-7f7615cbd67a.jpg', '2017-01-11', 'image/jpeg');
INSERT INTO `goods_upload` VALUES ('15', '21', '/electronic_sale/uploads/2017/01/11/', 'f771ac91-81da-45ab-9e06-1b8947542cf9.jpg', '2017-01-11', 'image/jpeg');
INSERT INTO `goods_upload` VALUES ('16', '22', '/electronic_sale/uploads/2017/01/11/', '4a62045f-c3a3-41fc-aef5-4b76bafc3e1a.jpg', '2017-01-11', 'image/jpeg');
INSERT INTO `goods_upload` VALUES ('19', '25', '/electronic_sale/uploads/2017/01/11/', '5f025fac-2d89-4647-a7bc-83163bb4732f.jpg', '2017-01-11', 'image/jpeg');
INSERT INTO `goods_upload` VALUES ('20', '26', '/electronic_sale/uploads/2017/01/11/', '72c9d4fd-e99a-4b0e-a19e-fae2c9d0f379.jpg', '2017-01-11', 'image/jpeg');
INSERT INTO `goods_upload` VALUES ('21', '27', '/electronic_sale/uploads/2017/01/15/', 'c277707d-b90c-48f9-9042-516c5ec9c6f6.jpg', '2017-01-15', 'image/jpeg');
INSERT INTO `goods_upload` VALUES ('22', '28', '/electronic_sale/uploads/2017/01/15/', '0990119a-370f-4d08-b875-31ca7eef583f.jpg', '2017-01-15', 'image/jpeg');
INSERT INTO `goods_upload` VALUES ('23', '29', '/electronic_sale/uploads/2017/01/15/', '866d7ac9-8303-4e4f-a3fc-a324ece0c31a.jpg', '2017-01-15', 'image/jpeg');
INSERT INTO `goods_upload` VALUES ('24', '30', '/electronic_sale/uploads/2017/01/17/', '8fcec0b0-192e-4864-878c-79461efc4790.jpg', '2017-01-17', 'image/jpeg');
INSERT INTO `goods_upload` VALUES ('25', '31', '/electronic_sale/uploads/2017/01/17/', '5c44576b-c341-4ec9-9828-8b88110925b1.jpg', '2017-01-17', 'image/jpeg');
INSERT INTO `goods_upload` VALUES ('26', '32', '/electronic_sale/uploads/2017/01/17/', '38053d28-c0a3-4b39-9006-7b73bb962516.jpg', '2017-01-17', 'image/jpeg');
INSERT INTO `goods_upload` VALUES ('27', '33', '/electronic_sale/uploads/2017/01/17/', '954eb213-1b45-4204-b112-eaebde2ce4e3.jpg', '2017-01-17', 'image/jpeg');
INSERT INTO `goods_upload` VALUES ('28', '34', '/electronic_sale/uploads/2017/01/17/', 'eb83a635-2099-4dbe-ba41-52bf5f49b839.jpg', '2017-01-17', 'image/jpeg');
INSERT INTO `goods_upload` VALUES ('29', '35', '/electronic_sale/uploads/2017/01/17/', '89aa3ad6-7abe-46ac-8f37-d1f692c3ad4b.jpg', '2017-01-17', 'image/jpeg');
INSERT INTO `goods_upload` VALUES ('30', '36', '/electronic_sale/uploads/2017/01/17/', 'e858a512-97ab-4791-a8d2-131499e62bd2.jpg', '2017-01-17', 'image/jpeg');
INSERT INTO `goods_upload` VALUES ('31', '37', '/electronic_sale/uploads/2017/01/17/', '60d226ab-a487-4ad6-a09d-8457805c086f.jpg', '2017-01-17', 'image/jpeg');
INSERT INTO `goods_upload` VALUES ('32', '38', '/electronic_sale/uploads/2017/01/17/', '45b395ea-e28b-455e-b916-9265d2378d04.jpg', '2017-01-17', 'image/jpeg');
INSERT INTO `goods_upload` VALUES ('33', '39', '/electronic_sale/uploads/2017/01/17/', 'dc110166-ee55-41f8-8250-fe43bf5934df.jpg', '2017-01-17', 'image/jpeg');
INSERT INTO `goods_upload` VALUES ('34', '40', '/electronic_sale/uploads/2017/01/17/', '868ffb22-968d-4bfd-9aa7-20faa954b8bf.jpg', '2017-01-17', 'image/jpeg');
INSERT INTO `goods_upload` VALUES ('35', '41', '/electronic_sale/uploads/2017/01/17/', 'e66a5d39-c20c-4a70-aafd-abe50364cf24.jpg', '2017-01-17', 'image/jpeg');
-- ----------------------------
-- Table structure for notice
-- ----------------------------
DROP TABLE IF EXISTS `notice`;
CREATE TABLE `notice` (
`notice_time` datetime DEFAULT NULL,
`notice_author` varchar(10) DEFAULT NULL,
`notice_word` varchar(1000) DEFAULT NULL
) ENGINE=InnoDB DEFAULT CHARSET=utf8;
-- ----------------------------
-- Records of notice
-- ----------------------------
-- ----------------------------
-- Table structure for orders
-- ----------------------------
DROP TABLE IF EXISTS `orders`;
CREATE TABLE `orders` (
`order_id` int(11) NOT NULL AUTO_INCREMENT,
`customer_id` int(11) NOT NULL,
`order_time` datetime DEFAULT NULL COMMENT '原定为订单时间,2017/3/2由ordersdetail.orders_date取代',
`order_state` varchar(10) DEFAULT NULL COMMENT '原定为订单付款状态,2017/3/2由ordersdetail.orders_states取代',
`order_price` int(11) DEFAULT NULL,
`goods_id` int(11) DEFAULT NULL,
`indent_id` int(11) DEFAULT NULL COMMENT '废弃不用',
PRIMARY KEY (`order_id`)
) ENGINE=InnoDB AUTO_INCREMENT=138 DEFAULT CHARSET=utf8;
-- ----------------------------
-- Records of orders
-- ----------------------------
INSERT INTO `orders` VALUES ('48', '11', '2017-02-25 23:47:10', '未付款', '5499', '28', null);
INSERT INTO `orders` VALUES ('49', '11', '2017-02-25 23:48:10', '未付款', '5499', '28', null);
INSERT INTO `orders` VALUES ('50', '11', '2017-02-25 23:48:29', '未付款', '5499', '28', null);
INSERT INTO `orders` VALUES ('51', '11', '2017-02-25 23:49:07', '未付款', '5499', '28', null);
INSERT INTO `orders` VALUES ('52', '11', '2017-02-25 23:49:22', '未付款', '5499', '28', null);
INSERT INTO `orders` VALUES ('53', '11', '2017-02-25 23:50:34', '未付款', '5499', '28', null);
INSERT INTO `orders` VALUES ('54', '11', '2017-02-25 23:50:50', '未付款', '5499', '28', null);
INSERT INTO `orders` VALUES ('55', '11', '2017-02-25 23:51:17', '未付款', '5499', '28', null);
INSERT INTO `orders` VALUES ('56', '11', '2017-02-25 23:53:15', '未付款', '5499', '28', null);
INSERT INTO `orders` VALUES ('57', '11', '2017-02-25 23:55:41', '未付款', '5499', '28', null);
INSERT INTO `orders` VALUES ('58', '11', '2017-02-25 23:56:22', '未付款', '5499', '28', null);
INSERT INTO `orders` VALUES ('59', '11', '2017-02-25 23:56:29', '未付款', '5499', '28', null);
INSERT INTO `orders` VALUES ('60', '11', '2017-02-25 23:56:40', '未付款', '5499', '28', null);
INSERT INTO `orders` VALUES ('61', '11', '2017-02-25 23:56:54', '未付款', '5499', '28', null);
INSERT INTO `orders` VALUES ('62', '11', '2017-02-25 23:57:07', '未付款', '5499', '28', null);
INSERT INTO `orders` VALUES ('63', '11', '2017-02-25 23:59:00', '未付款', '5499', '28', null);
INSERT INTO `orders` VALUES ('64', '11', '2017-02-25 23:59:20', '未付款', '5499', '28', null);
INSERT INTO `orders` VALUES ('65', '11', '2017-02-25 23:59:42', '未付款', '5499', '28', null);
INSERT INTO `orders` VALUES ('66', '11', '2017-02-25 23:59:52', '未付款', '5499', '28', null);
INSERT INTO `orders` VALUES ('67', '11', '2017-02-26 00:00:33', '未付款', '5499', '28', null);
INSERT INTO `orders` VALUES ('68', '11', '2017-02-26 00:02:00', '未付款', '5499', '28', null);
INSERT INTO `orders` VALUES ('69', '11', '2017-02-26 00:03:01', '未付款', '5499', '28', null);
INSERT INTO `orders` VALUES ('70', '11', '2017-02-26 00:03:15', '未付款', '5499', '28', null);
INSERT INTO `orders` VALUES ('71', '11', '2017-02-26 00:04:01', '未付款', '5499', '28', null);
INSERT INTO `orders` VALUES ('72', '11', '2017-02-26 00:04:08', '未付款', '5499', '28', null);
INSERT INTO `orders` VALUES ('73', '11', '2017-02-26 00:04:36', '未付款', '5499', '28', null);
INSERT INTO `orders` VALUES ('74', '11', '2017-02-26 00:04:44', '未付款', '5499', '28', null);
INSERT INTO `orders` VALUES ('75', '11', '2017-02-26 00:08:04', '未付款', '5499', '28', null);
INSERT INTO `orders` VALUES ('76', '11', '2017-02-26 00:08:12', '未付款', '5499', '28', null);
INSERT INTO `orders` VALUES ('77', '11', '2017-02-26 00:08:19', '未付款', '5499', '28', null);
INSERT INTO `orders` VALUES ('78', '11', '2017-02-26 00:08:29', '未付款', '5499', '28', null);
INSERT INTO `orders` VALUES ('79', '11', '2017-02-26 00:08:36', '未付款', '5499', '28', null);
INSERT INTO `orders` VALUES ('80', '11', '2017-02-26 00:15:13', '未付款', '5499', '28', null);
INSERT INTO `orders` VALUES ('128', '11', '2017-02-26 18:35:45', '未付款', '5499', '28', null);
INSERT INTO `orders` VALUES ('132', '12', '2017-03-02 18:27:30', '未付款', '2999', '30', null);
INSERT INTO `orders` VALUES ('133', '12', '2017-03-02 18:27:42', '未付款', '3299', '33', null);
INSERT INTO `orders` VALUES ('134', '11', '2017-03-03 20:24:20', '未付款', '4999', '20', null);
INSERT INTO `orders` VALUES ('135', '11', '2017-03-05 16:25:23', '未付款', '7999', '25', null);
INSERT INTO `orders` VALUES ('136', '11', '2017-03-06 10:51:55', '未付款', '5299', '18', null);
INSERT INTO `orders` VALUES ('137', '11', '2017-03-12 21:51:00', '未付款', '7999', '25', null);
-- ----------------------------
-- Table structure for ordersdetail
-- ----------------------------
DROP TABLE IF EXISTS `ordersdetail`;
CREATE TABLE `ordersdetail` (
`order_date` datetime DEFAULT NULL,
`detail_id` int(11) NOT NULL AUTO_INCREMENT,
`customer_id` int(11) NOT NULL COMMENT '对应Orders表中custom_id',
`order_cname` varchar(255) DEFAULT NULL,
`order_caddress` varchar(255) DEFAULT NULL,
`order_cphone` varchar(255) DEFAULT NULL,
`order_states` varchar(10) DEFAULT NULL COMMENT '2017/3/2,代表订单状态',
PRIMARY KEY (`detail_id`),
KEY `order_id` (`customer_id`)
) ENGINE=InnoDB AUTO_INCREMENT=42 DEFAULT CHARSET=utf8;
-- ----------------------------
-- Records of ordersdetail
-- ----------------------------
INSERT INTO `ordersdetail` VALUES ('2017-03-02 10:32:14', '4', '11', '陈明俊', '华纳农业大学', '65464564', '未付款');
INSERT INTO `ordersdetail` VALUES ('2017-03-02 17:36:35', '10', '12', '程敏骏', '华南农业大学', '767668', '未付款');
INSERT INTO `ordersdetail` VALUES ('2017-03-02 18:26:08', '11', '12', '都敏俊', '华南农业大学', '654253', '未付款');
INSERT INTO `ordersdetail` VALUES ('2017-03-02 18:27:24', '12', '12', '王晓梅', '河南三门峡', '654654', '未付款');
INSERT INTO `ordersdetail` VALUES ('2017-03-02 18:28:08', '13', '12', '何婷', '广东湛江', '654654', '未付款');
INSERT INTO `ordersdetail` VALUES ('2017-03-12 21:24:06', '17', '11', 'tes', 'tst', 'tst', '未付款');
INSERT INTO `ordersdetail` VALUES ('2017-03-12 21:29:21', '18', '11', 'tes', 'tst', 'tst', '未付款');
INSERT INTO `ordersdetail` VALUES ('2017-03-12 21:30:19', '19', '11', 'tes', 'tst', 'tst', '未付款');
INSERT INTO `ordersdetail` VALUES ('2017-03-12 21:30:57', '20', '11', 'tes', 'tst', 'tst', '未付款');
INSERT INTO `ordersdetail` VALUES ('2017-03-12 21:33:46', '21', '11', 'tes', 'tst', 'tst', '未付款');
INSERT INTO `ordersdetail` VALUES ('2017-03-12 21:36:14', '22', '11', 'tes', 'tst', 'tst', '未付款');
INSERT INTO `ordersdetail` VALUES ('2017-04-12 09:06:12', '26', '11', '1', '1', '1111111', '未付款');
INSERT INTO `ordersdetail` VALUES ('2017-04-12 09:07:27', '27', '11', '1', '1', '1111111', '未付款');
INSERT INTO `ordersdetail` VALUES ('2017-04-12 09:08:30', '28', '11', '1', '1', '1111111', '未付款');
INSERT INTO `ordersdetail` VALUES ('2017-04-12 09:26:57', '36', '11', 'eqwe', '21312', '12312', '未付款');
INSERT INTO `ordersdetail` VALUES ('2017-04-12 09:28:47', '37', '11', 'eqwe', '21312', '12312', '未付款');
INSERT INTO `ordersdetail` VALUES ('2017-04-12 09:35:59', '39', '11', '11', '11', '332', '未付款');
INSERT INTO `ordersdetail` VALUES ('2017-04-12 09:37:46', '40', '11', '4234', '23423', '423423', '未付款');
INSERT INTO `ordersdetail` VALUES ('2017-04-12 09:38:12', '41', '11', 'werwe', 'werwerw', 'werwer', '未付款');
-- ----------------------------
-- Table structure for shopping_cart
-- ----------------------------
DROP TABLE IF EXISTS `shopping_cart`;
CREATE TABLE `shopping_cart` (
`cart_id` int(11) NOT NULL,
`customer_id` int(11) NOT NULL,
`goods_id` int(11) NOT NULL,
PRIMARY KEY (`cart_id`),
KEY `customer_id` (`customer_id`),
KEY `shopping_cart_ibfk_2` (`goods_id`),
CONSTRAINT `shopping_cart_ibfk_1` FOREIGN KEY (`customer_id`) REFERENCES `customer` (`customer_id`),
CONSTRAINT `shopping_cart_ibfk_2` FOREIGN KEY (`goods_id`) REFERENCES `goods` (`goods_id`) ON DELETE CASCADE ON UPDATE CASCADE
) ENGINE=InnoDB DEFAULT CHARSET=utf8;
-- ----------------------------
-- Records of shopping_cart
-- ----------------------------
Loading...
马建仓 AI 助手
尝试更多
代码解读
代码找茬
代码优化