Shopingmall_ERD
Tables (14)
Product_cart
- cart_ID — CHAR(10) — Primary key — NOT NULL
- product_ID — CHAR(10)
- recipe_id — CHAR(10) — Foreign key → recipe.recipe_id — NOT NULL
Untitled
- product_id — CHAR(10) — Foreign key → product.product_id — NOT NULL
- proudctTag — CHAR(5) — Foreign key → productTag.proudctTag — NOT NULL
exchange
- exchange_id — CHAR(10) — Primary key — NOT NULL
- exchange_issue — VARCHAR(100)
- recipe_id — CHAR(10) — NOT NULL
- recipe_id (recipe_id2) — CHAR(10) — Foreign key → recipe.recipe_id — NOT NULL
main_category
- main_category_id — CHAR(10) — Primary key — NOT NULL
- category — VARCHAR(100)
payment
- paymentID — CHAR(10) — Primary key — NOT NULL
- price — INT
- location — VARCHAR(100)
- recipe_id — CHAR(10) — NOT NULL
- recipe_id (recipe_id2) — CHAR(10) — Foreign key → recipe.recipe_id — NOT NULL
product
- product_id — CHAR(10) — Primary key — NOT NULL
- product_name — VARCHAR(100)
- desc — VARCHAR(100)
- product_price — INT
- season — CHAR(5)
- gender — CHAR(5)
- size — CHAR(10)
- brand — VARCHAR(100)
- origin — VARCHAR(100)
- stock — INT
- soldOut — TINYINT
- color — CHAR(10)
- sub_category — CHAR(10) — NOT NULL
- proudctTag — CHAR(5) — NOT NULL
- cart_ID — CHAR(10) — NOT NULL
- sub_category (sub_category2) — CHAR(10) — Foreign key → sub_category.sub_category — NOT NULL
- cart_ID (cart_ID2) — CHAR(10) — Foreign key → Product_cart.cart_ID — NOT NULL
productTag
- proudctTag — CHAR(5) — Primary key — NOT NULL
- TagName — CHAR(10)
- product_id — CHAR(10) — NOT NULL
product_image
- Key — CHAR(10) — Primary key — NOT NULL
- url — VARCHAR(100)
- product_id — CHAR(10) — NOT NULL
- product_id (product_id2) — CHAR(10) — Foreign key → product.product_id — NOT NULL
product_like
- producLike_id — CHAR(10) — Primary key — NOT NULL
- grade — VARCHAR(100)
- review — VARCHAR(100)
- like — INT
- isdiscount — CHAR(4)
- discount — INT
- ranking — INT
- sales_rate — CHAR(8)
- product_id2 — CHAR(10) — NOT NULL
- product_id — CHAR(10) — Foreign key → product.product_id — NOT NULL
product_order
- product_id — CHAR(10) — NOT NULL
- recipe_id — CHAR(10) — NOT NULL
- product_id (product_id2) — CHAR(10) — Foreign key → product.product_id — NOT NULL
- recipe_id (recipe_id2) — CHAR(10) — Foreign key → recipe.recipe_id — NOT NULL
recipe
- recipe_id — CHAR(10) — Primary key — NOT NULL
- delivery — CHAR(5)
- invoice_number — VARCHAR(100)
- address — VARCHAR(30)
- delivery_company — CHAR(10)
- user_id — VARCHAR(20) — NOT NULL
- cart_ID — VARCHAR(20) — NOT NULL
- user_id (user_id2) — VARCHAR(20) — Foreign key → user.user_id — NOT NULL
refund
- refund_id — CHAR(10) — Primary key — NOT NULL
- refund_issue — VARCHAR(100)
- product_photo — VARCHAR(100)
- isphoto — TINYINT(1)
- paymentID — CHAR(10) — NOT NULL
- paymentID (paymentID2) — CHAR(10) — Foreign key → payment.paymentID — NOT NULL
sub_category
- sub_category — CHAR(10) — Primary key — NOT NULL
- sub_category_name — VARCHAR(100)
- main_category_id — CHAR(10) — NOT NULL
- main_category_id (main_category_id2) — CHAR(10) — Foreign key → main_category.main_category_id — NOT NULL
user
- user_id — VARCHAR(20) — Primary key — NOT NULL
- user_pw — VARCHAR(30)
- user_email — VARCHAR(40)
- user_phone — CHAR(13)
- user_address — VARCHAR(100)
- user_personal — CHAR(15)
- nickname — CHAR(10)
- profile_photo — VARCHAR(100)
- photo_check — TINYINT
- first_message — VARCHAR(100)