MySQL Create Table SQL
Table Structure: okayapi_hc_group_buy:/tablelist/okayapi_hc_group_buy.html
-- MySQL Table okayapi_hc_group_buy
-- From: OkayAPI.com
CREATE TABLE `okayapi_hc_group_buy` (
`id` bigint(20) unsigned NOT NULL AUTO_INCREMENT,
`buy_id` varchar(30) NOT NULL COMMENT '团购购买ID',
`batch_id` varchar(30) NOT NULL COMMENT '批次ID',
`store_id` varchar(30) NOT NULL COMMENT '商户ID,分片ID',
`product_id` varchar(30) NOT NULL COMMENT '产品ID',
`spec_id` varchar(30) NOT NULL COMMENT '产品规格ID',
`group_id` varchar(30) NOT NULL COMMENT '团购ID',
`persion_id` varchar(30) NOT NULL COMMENT '用户ID',
`persion_name` varchar(256) NOT NULL COMMENT '用户名称',
`buy_count` int(11) NOT NULL COMMENT '购买数量',
`group_price` decimal(8,2) NOT NULL COMMENT '团购时单价',
`amount` int(11) NOT NULL COMMENT '付款金额',
`state` varchar(12) NOT NULL DEFAULT '1001' COMMENT '1001 拼团中,2002 拼团成功 3003 拼团失败',
`create_time` timestamp NOT NULL DEFAULT CURRENT_TIMESTAMP COMMENT '创建时间',
`status_cd` varchar(2) NOT NULL DEFAULT '0' COMMENT '数据状态',
KEY `buy_id` (`buy_id`),
KEY `batch_id` (`batch_id`),
KEY `store_id` (`store_id`),
KEY `product_id` (`product_id`),
KEY `spec_id` (`spec_id`),
KEY `group_id` (`group_id`),
KEY `persion_id` (`persion_id`),
KEY `persion_name` (`persion_name`),
KEY `buy_count` (`buy_count`),
KEY `group_price` (`group_price`),
KEY `amount` (`amount`),
KEY `state` (`state`),
KEY `create_time` (`create_time`),
KEY `status_cd` (`status_cd`),
PRIMARY KEY (`id`)
) ENGINE=InnoDB COMMENT '小区物业管理系统-团购';
After replication, you can go to the database to create the database table.
MySQL database table structure design
Displaying 1-14 of 14 results.
Field Name | Field Type | Default | IS NULL | Field Comment | Index | Demo Data |
---|---|---|---|---|---|---|
buy_id | varchar(30) | 否 | 团购购买ID | |||
batch_id | varchar(30) | 否 | 批次ID | |||
store_id | varchar(30) | 否 | 商户ID,分片ID | |||
product_id | varchar(30) | 否 | 产品ID | |||
spec_id | varchar(30) | 否 | 产品规格ID | |||
group_id | varchar(30) | 否 | 团购ID | |||
persion_id | varchar(30) | 否 | 用户ID | |||
persion_name | varchar(256) | 否 | 用户名称 | |||
buy_count | int(11) | 否 | 购买数量 | |||
group_price | decimal(8,2) | 否 | 团购时单价 | |||
amount | int(11) | 否 | 付款金额 | |||
state | varchar(12) | 1001 | 否 | 1001 拼团中,2002 拼团成功 3003 拼团失败 | 1001 | |
create_time | timestamp | CURRENT_TIMESTAMP | 是 | 创建时间 | CURRENT_TIMESTAMP | |
status_cd | varchar(2) | 0 | 否 | 数据状态 | 0 |