USE `cnbg_20240511_001`;

SET NAMES utf8mb4;
SET FOREIGN_KEY_CHECKS = 0;

-- ----------------------------
-- Table structure for wm_drug_quiz_rel
-- ----------------------------
DROP TABLE IF EXISTS `wm_drug_quiz_rel`;
CREATE TABLE `wm_drug_quiz_rel`
(
    `drug_id`     INT UNSIGNED NOT NULL COMMENT '药品ID',
    `quiz_id`     INT UNSIGNED NOT NULL COMMENT '试卷ID',
    `create_by`   VARCHAR(64)  NOT NULL COMMENT '创建人',
    `update_by`   VARCHAR(64)  NOT NULL COMMENT '修改人',
    `create_time` DATETIME     NOT NULL DEFAULT CURRENT_TIMESTAMP COMMENT '创建时间',
    `update_time` DATETIME     NOT NULL DEFAULT CURRENT_TIMESTAMP ON UPDATE CURRENT_TIMESTAMP COMMENT '修改时间',
    PRIMARY KEY `pk_id` (`drug_id`, `quiz_id`) USING BTREE,
    KEY `idx_qid` (`quiz_id`) USING BTREE
) ENGINE = InnoDB
  DEFAULT CHARSET = utf8mb4
  COLLATE = utf8mb4_general_ci
  ROW_FORMAT = DYNAMIC COMMENT ='药品试卷关系';


-- ----------------------------
-- Records of wm_drug_quiz_rel
-- ----------------------------
BEGIN;
COMMIT;


SET FOREIGN_KEY_CHECKS = 1;
