2015-07-7
Today introduces the background database design of shopping website, the database is using MySQL
(1) Create a database in MySQL, named Test
(2) Three new data tables are created under test, respectively mismatch_user (User Information table), Goods (Commodity information table), Shop_car (Shopping cart information sheet)
(3) Add information for each table as follows:
Mismatch_user:
Where user_id is the user ID information, username is the user name, password is the login password, mail is the user mailbox.
Goods
Where name is the product name, price is the commodity value, image holds the location information of the picture, number is the remaining quantity of the goods, kind is the product type (there are three kinds of kind=1, 2, 3 respectively).
Shop_car:
Where username is the user name (used to indicate whose shopping cart this item is in), name is the commodity, price is the commodity, and image holds the location information.
php-Shopping website development and design (II.)