Blogger Information
Blog 47
fans 0
comment 3
visits 45064
Popular Tutorials
More>
Latest Downloads
More>
Web Effects
Website Source Code
Website Materials
Front End Template
创建商城项目数据库表
江流
Original
848 people have browsed it

创建商城项目

  1. #创建数据库
  2. CREATE DATABASE `proDB`;
  3. #用户表
  4. DROP TABLE IF EXISTS `php_user`;
  5. CREATE TABLE `php_user`(
  6. `id` INT NOT NULL AUTO_INCREMENT KEY,
  7. `account` VARCHAR(20) NOT NULL,
  8. `password` VARCHAR(32) NOT NULL,
  9. `name` VARCHAR(20),
  10. `email` VARCHAR(50),
  11. `phone` INT,
  12. `create_time` INT,
  13. `update_time` INT,
  14. `state` TINYINT
  15. ) DEFAULT CHARSET=utf8;
  16. #商品表
  17. DROP TABLE IF EXISTS `php_product`;
  18. CREATE TABLE `php_product`(
  19. `id` INT NOT NULL AUTO_INCREMENT KEY,
  20. `pro_Code` VARCHAR(20) NOT NULL,
  21. `pro_name` VARCHAR(20), #商品名称
  22. `price` float(10,2), #价格
  23. `count` INT, #库存数量
  24. `create_time` INT,
  25. `update_time` INT
  26. ) DEFAULT CHARSET=utf8;
  27. #订单表
  28. DROP TABLE IF EXISTS `php_order`;
  29. CREATE TABLE `php_order`(
  30. `id` INT NOT NULL AUTO_INCREMENT KEY,
  31. `pro_Code` VARCHAR(20) NOT NULL, #商品编号
  32. `account` VARCHAR(20), #用户账号
  33. `quantity` INT, #订单数量
  34. `create_time` INT,
  35. `update_time` INT
  36. ) DEFAULT CHARSET=utf8;
Correcting teacher:PHPzPHPz

Correction status:qualified

Teacher's comments:
Statement of this Website
The copyright of this blog article belongs to the blogger. Please specify the address when reprinting! If there is any infringement or violation of the law, please contact admin@php.cn Report processing!
All comments Speak rationally on civilized internet, please comply with News Comment Service Agreement
0 comments
Author's latest blog post