【已解决】Doris 主键模型下存在主键重复问题

Viewed 99

doris版本 2.0.4
image.png

模型表结构

CREATE TABLE `dwd_lcyl_cdr_check_application_records` (
  `electronicrequestnoteid` varchar(60) NOT NULL COMMENT '电子申请单编号',
  `exam_apply_org_name` varchar(300) NOT NULL COMMENT '检查申请机构代码',
  `exam_item_code` varchar(384) NOT NULL COMMENT '检查项目代码',
  `hospital_code` varchar(300) NOT NULL COMMENT '院区编号',
  `org_code` varchar(150) NOT NULL COMMENT '申请组织机构代码',
  `main_cable_no` varchar(150) NULL COMMENT '患者主索引号',
  `exam_specimen_no` varchar(150) NULL COMMENT '检查标本号',
  `outpat_no` varchar(60) NULL COMMENT '门(急)诊就诊号'
) ENGINE=OLAP
UNIQUE KEY(`electronicrequestnoteid`, `exam_apply_org_name`, `exam_item_code`, `hospital_code`, `org_code`)
COMMENT '检查申请记录'
DISTRIBUTED BY HASH(`electronicrequestnoteid`, `exam_apply_org_name`, `exam_item_code`, `hospital_code`, `org_code`) BUCKETS 10
PROPERTIES (
"replication_allocation" = "tag.location.default: 3",
"is_being_synced" = "false",
"storage_format" = "V2",
"light_schema_change" = "true",
"disable_auto_compaction" = "false",
"enable_single_replica_compaction" = "false"
);
1 Answers

本地未复现,可以加微信Faith_xzc一起来看看
应该是有的行有空格之类的