-- ----------------------------
-- 试卷与题目关系表
-- ----------------------------
CREATE TABLE `train_exam`.`ex_paper_question`  (
`id` bigint(20) UNSIGNED NOT NULL AUTO_INCREMENT COMMENT '主键' ,
`paper_id` bigint(20) NOT NULL COMMENT '考卷id',
`question_id` bigint(20) NOT NULL COMMENT '题目id',
`question_type` tinyint NOT NULL DEFAULT 1 COMMENT '考题类型(1单选题，2多选题，3判断题 默认1)',
`score` int NOT NULL COMMENT '分数',
`create_time` datetime NOT NULL DEFAULT CURRENT_TIMESTAMP COMMENT '创建时间',
`create_by` varchar(50) NULL DEFAULT NULL COMMENT '创建人',
`update_time` datetime NOT NULL DEFAULT CURRENT_TIMESTAMP ON UPDATE CURRENT_TIMESTAMP COMMENT '更新时间',
`update_by` varchar(50) NULL DEFAULT NULL COMMENT '更新人',
`remark` varchar(10) CHARACTER SET utf8mb4 COLLATE utf8mb4_general_ci NULL DEFAULT NULL COMMENT '备注',
PRIMARY KEY (`id`) USING BTREE,
UNIQUE KEY `paper_question_id` (`paper_id`,`question_id`)
) ENGINE = InnoDB CHARACTER SET = utf8mb4 COLLATE = utf8mb4_general_ci COMMENT = '试卷与题目关系表' ROW_FORMAT = DYNAMIC;
