From 5f1385a50bb28c5007933b53d7e3739fa0a826a2 Mon Sep 17 00:00:00 2001 From: Chen Zhang Date: Wed, 27 Nov 2024 21:32:26 +0800 Subject: [PATCH] [fix](unique key) getEnableUniqueKeyMergeOnWrite should check keys type --- .../src/main/java/org/apache/doris/catalog/OlapTable.java | 3 +++ 1 file changed, 3 insertions(+) diff --git a/fe/fe-core/src/main/java/org/apache/doris/catalog/OlapTable.java b/fe/fe-core/src/main/java/org/apache/doris/catalog/OlapTable.java index ec3bd2acbc57d6..0a664bafb8d2d6 100644 --- a/fe/fe-core/src/main/java/org/apache/doris/catalog/OlapTable.java +++ b/fe/fe-core/src/main/java/org/apache/doris/catalog/OlapTable.java @@ -2831,6 +2831,9 @@ public boolean getEnableUniqueKeyMergeOnWrite() { if (tableProperty == null) { return false; } + if (getKeysType() != KeysType.UNIQUE_KEYS) { + return false; + } return tableProperty.getEnableUniqueKeyMergeOnWrite(); }