test
Tables (13)
cart
- cart_id — BIGINT
- customer_id — BIGINT — Foreign key → customer.customer_id — NOT NULL
- product_id — BIGINT — Foreign key → product.product_id — NOT NULL
- quantity — INT
- created_at — DATETIME
coupon
- coupon_id — BIGINT
- coupon_name — VARCHAR(200)
- discount_amount — INT
- expired_at — DATETIME
customer
- customer_id — BIGINT
- customer_name — VARCHAR(100) — NOT NULL
- customer_phone — VARCHAR(20)
- joined_date — DATETIME
order_item
- order_item_id — BIGINT
- order_id — BIGINT — Foreign key → order_table.order_id — NOT NULL
- product_id — BIGINT — Foreign key → product.product_id — NOT NULL
- photo_id — BIGINT — Foreign key → photo.photo_id
- order_item_quantity — INT
order_status
- order_status_id — BIGINT
- order_id — BIGINT — Foreign key → order_table.order_id — NOT NULL
- status — VARCHAR(50)
- status_changed_at — DATETIME
order_table
- order_id — BIGINT
- order_name — VARCHAR(200)
- order_price — INT
- customer_id — BIGINT — Foreign key → customer.customer_id — NOT NULL
- created_at — DATETIME
payment
- payment_id — BIGINT
- payment_price — INT — NOT NULL
- payment_name — VARCHAR(100)
- order_id — BIGINT — Foreign key → order_table.order_id — NOT NULL
- created_at — DATETIME
photo
- photo_id — BIGINT
- customer_id — BIGINT — Foreign key → customer.customer_id — NOT NULL
- product_id — BIGINT — Foreign key → product.product_id — NOT NULL
- photo_origin_name — VARCHAR(255)
- photo_show_name — VARCHAR(255)
- photo_path — VARCHAR(500)
- photo_show_file_name — VARCHAR(255)
product
- product_id — BIGINT
- seller_id — BIGINT — Foreign key → seller.seller_id — NOT NULL
- product_name — VARCHAR(200) — NOT NULL
- product_type — VARCHAR(50)
- product_price — INT — NOT NULL
- product_slice — VARCHAR(20)
review
- review_id — BIGINT
- product_id — BIGINT — Foreign key → product.product_id — NOT NULL
- customer_id — BIGINT — Foreign key → customer.customer_id — NOT NULL
- rating — INT
- review_text — TEXT
- created_at — DATETIME
seller
- seller_id — BIGINT
- seller_name — VARCHAR(200) — NOT NULL
- seller_phone — VARCHAR(20)
- seller_email — VARCHAR(200)
- created_at — DATETIME
settlement
- settlement_id — BIGINT
- order_item_id — BIGINT — Foreign key → order_item.order_item_id — NOT NULL
- seller_id — BIGINT — Foreign key → seller.seller_id — NOT NULL
- settlement_amount — INT — NOT NULL
- settlement_status — VARCHAR(20)
- settled_at — DATETIME
shipment
- shipment_id — BIGINT
- order_id — BIGINT — Foreign key → order_table.order_id — NOT NULL
- shipment_status — VARCHAR(50)
- shipment_company — VARCHAR(100)
- tracking_number — VARCHAR(200)
- shipped_at — DATETIME