study_comment TABLE 컬럼 설명
Table 생성 SQL 문
CREATE TABLE `sitedb`.`study_comment` (
id BIGINT(20) NOT NULL AUTO_INCREMENT,
user_id BIGINT(20),
study_id BIGINT(20) NOT NULL,
comment TEXT NOT NULL,
comment_class BOOLEAN DEFAULT 0,
comment_order INT DEFAULT 0,
comment_group INT,
comment_visible BOOLEAN DEFAULT 0,
comment_state VARCHAR(15) DEFAULT 'active',
create_date DATETIME DEFAULT NOW(),
PRIMARY KEY (id),
FOREIGN KEY (user_id) REFERENCES user(id) ON DELETE SET NULL ON UPDATE CASCADE,
FOREIGN KEY (study_id) REFERENCES study(id) ON DELETE CASCADE ON UPDATE CASCADE
)
ENGINE=InnoDB
DEFAULT CHARSET=utf8
COLLATE=utf8_general_ci;
SQL
복사