/*
 Navicat Premium Dump SQL

 Source Server         : fhxy-192.168.1.61-polardbx
 Source Server Type    : MySQL
 Source Server Version : 80032 (8.0.32-X-Cluster-8.4.19-20241112)
 Source Host           : 192.168.1.61:4886
 Source Schema         : pla-chem-sim-dev-2

 Target Server Type    : MySQL
 Target Server Version : 80032 (8.0.32-X-Cluster-8.4.19-20241112)
 File Encoding         : 65001

 Date: 20/04/2025 17:38:24
*/

SET NAMES utf8mb4;
SET FOREIGN_KEY_CHECKS = 0;

-- ----------------------------
-- Table structure for mx_real_exam_fault
-- ----------------------------
DROP TABLE IF EXISTS `mx_real_exam_fault`;
CREATE TABLE `mx_real_exam_fault`  (
  `ref_id` bigint NOT NULL AUTO_INCREMENT COMMENT '关联ID',
  `exam_id` bigint NOT NULL COMMENT '考试ID',
  `fault_id` char(12) CHARACTER SET utf8mb4 COLLATE utf8mb4_general_ci NOT NULL DEFAULT '' COMMENT '故障ID',
  `ref_type` char(1) CHARACTER SET utf8mb4 COLLATE utf8mb4_general_ci NOT NULL DEFAULT '' COMMENT '关联类型:[1]-选择题,[2]-模拟器维修故障',
  `flag` char(1) CHARACTER SET utf8mb4 COLLATE utf8mb4_general_ci NOT NULL DEFAULT '7' COMMENT '选择状态:[7]-未知,[1]-选中,[0]-没有选中',
  `ref_state` char(1) CHARACTER SET utf8mb4 COLLATE utf8mb4_general_ci NOT NULL DEFAULT '0' COMMENT '故障ID关联状态:[0]-初始化,[1]-已经清除故障,[2]-故障已经下发~出题值填充,[3]-中间轮询读取~中间答题值填充,[4]-交卷~最终答题值填充',
  `answer_right` char(1) CHARACTER SET utf8mb4 COLLATE utf8mb4_general_ci NOT NULL DEFAULT '0' COMMENT '答题正确:[0]-初始化,[1]-正确,[2]-错误',
  `choice_question_value` char(12) CHARACTER SET utf8mb4 COLLATE utf8mb4_general_ci NULL DEFAULT '' COMMENT '选择题的出题数值/正确答案',
  `choice_answer_value` char(12) CHARACTER SET utf8mb4 COLLATE utf8mb4_general_ci NULL DEFAULT '' COMMENT '选择题的答题数值/学员填写答案',
  `sim_fault_question_value` char(8) CHARACTER SET utf8mb4 COLLATE utf8mb4_general_ci NULL DEFAULT '' COMMENT '模拟器出题值/电阻代表值',
  `sim_fault_answer_value` char(8) CHARACTER SET utf8mb4 COLLATE utf8mb4_general_ci NULL DEFAULT '' COMMENT '模拟器答题值/电阻代表值',
  `minus` int NULL DEFAULT 0 COMMENT '减分值,计正数',
  `create_by` varchar(64) CHARACTER SET utf8mb4 COLLATE utf8mb4_general_ci NULL DEFAULT NULL COMMENT '创建者',
  `createtime` int NULL DEFAULT 0,
  `create_time` datetime NULL DEFAULT NULL COMMENT '创建时间',
  `update_by` varchar(64) CHARACTER SET utf8mb4 COLLATE utf8mb4_general_ci NULL DEFAULT NULL COMMENT '更新者',
  `updatetime` int NULL DEFAULT 0,
  `update_time` datetime NULL DEFAULT NULL COMMENT '更新时间',
  `remark` varchar(500) CHARACTER SET utf8mb4 COLLATE utf8mb4_general_ci NULL DEFAULT NULL COMMENT '备注',
  PRIMARY KEY (`ref_id`) USING BTREE,
  INDEX `exam_id`(`exam_id` ASC) USING BTREE,
  INDEX `flag`(`flag` ASC) USING BTREE,
  INDEX `fault_id`(`fault_id` ASC) USING BTREE,
  INDEX `answer_right`(`answer_right` ASC) USING BTREE
) ENGINE = InnoDB AUTO_INCREMENT = 19763 CHARACTER SET = utf8mb4 COLLATE = utf8mb4_general_ci COMMENT = 'sim-考试故障关联表' ROW_FORMAT = DYNAMIC;

SET FOREIGN_KEY_CHECKS = 1;
