MySQL Create Table SQL
Table Structure: okayapi_question:/tablelist/okayapi_question.html
-- MySQL Table okayapi_question
-- From: OkayAPI.com
CREATE TABLE `okayapi_question` (
`id` bigint(20) unsigned NOT NULL AUTO_INCREMENT,
`question_content` varchar(255) NOT NULL COMMENT '问题内容',
`question_detail` text NOT NULL COMMENT '问题说明',
`published_uid` int(11) NOT NULL COMMENT '发布用户UID',
`answer_count` int(11) NOT NULL DEFAULT '0' COMMENT '回答计数',
`answer_users` int(11) NOT NULL DEFAULT '0' COMMENT '回答人数',
`view_count` int(11) NOT NULL DEFAULT '0' COMMENT '浏览次数',
`focus_count` int(11) NOT NULL DEFAULT '0' COMMENT '关注数',
`comment_count` int(11) NOT NULL DEFAULT '0' COMMENT '评论数',
`category_id` int(11) NOT NULL DEFAULT '0' COMMENT '分类 ID',
`agree_count` int(11) NOT NULL DEFAULT '0' COMMENT '回复赞同数总和',
`against_count` int(11) NOT NULL DEFAULT '0' COMMENT '回复反对数总和',
`okayapi_question_lock` tinyint(1) NOT NULL DEFAULT '0' COMMENT '是否锁定',
`anonymous` tinyint(1) NOT NULL DEFAULT '0' COMMENT '',
`thanks_count` int(10) NOT NULL DEFAULT '0' COMMENT '',
KEY `question_content` (`question_content`),
KEY `question_detail` (`question_detail`),
KEY `published_uid` (`published_uid`),
KEY `answer_count` (`answer_count`),
KEY `answer_users` (`answer_users`),
KEY `view_count` (`view_count`),
KEY `focus_count` (`focus_count`),
KEY `comment_count` (`comment_count`),
KEY `category_id` (`category_id`),
KEY `agree_count` (`agree_count`),
KEY `against_count` (`against_count`),
KEY `okayapi_question_lock` (`okayapi_question_lock`),
KEY `anonymous` (`anonymous`),
KEY `thanks_count` (`thanks_count`),
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 |
---|---|---|---|---|---|---|
question_content | varchar(255) | 否 | 问题内容 | |||
question_detail | text | 是 | 问题说明 | |||
published_uid | int(11) | 是 | 发布用户UID | |||
answer_count | int(11) | 0 | 否 | 回答计数 | 0 | |
answer_users | int(11) | 0 | 否 | 回答人数 | 0 | |
view_count | int(11) | 0 | 否 | 浏览次数 | 0 | |
focus_count | int(11) | 0 | 否 | 关注数 | 0 | |
comment_count | int(11) | 0 | 否 | 评论数 | 0 | |
category_id | int(11) | 0 | 否 | 分类 ID | 0 | |
agree_count | int(11) | 0 | 否 | 回复赞同数总和 | 0 | |
against_count | int(11) | 0 | 否 | 回复反对数总和 | 0 | |
okayapi_question_lock | tinyint(1) | 0 | 否 | 是否锁定 | 0 | |
anonymous | tinyint(1) | 0 | 否 | 0 | ||
thanks_count | int(10) | 0 | 否 | 0 |