From 6ce9c67383d6a2b6c7169037896905fc709f3a8a Mon Sep 17 00:00:00 2001 From: morrySnow <101034200+morrySnow@users.noreply.github.com> Date: Tue, 16 Jan 2024 17:10:54 +0800 Subject: [PATCH] [fix](Nereids) struct type coercion call wrong api (#30018) --- .../java/org/apache/doris/nereids/util/TypeCoercionUtils.java | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/fe/fe-core/src/main/java/org/apache/doris/nereids/util/TypeCoercionUtils.java b/fe/fe-core/src/main/java/org/apache/doris/nereids/util/TypeCoercionUtils.java index 63a6a552f6..185bcc055b 100644 --- a/fe/fe-core/src/main/java/org/apache/doris/nereids/util/TypeCoercionUtils.java +++ b/fe/fe-core/src/main/java/org/apache/doris/nereids/util/TypeCoercionUtils.java @@ -1120,7 +1120,7 @@ public class TypeCoercionUtils { } List newFields = Lists.newArrayList(); for (int i = 0; i < leftFields.size(); i++) { - Optional newDataType = findCommonComplexTypeForComparison(leftFields.get(i).getDataType(), + Optional newDataType = findWiderTypeForTwoForComparison(leftFields.get(i).getDataType(), rightFields.get(i).getDataType(), intStringToString); if (newDataType.isPresent()) { newFields.add(leftFields.get(i).withDataType(newDataType.get())); @@ -1348,7 +1348,7 @@ public class TypeCoercionUtils { } List newFields = Lists.newArrayList(); for (int i = 0; i < leftFields.size(); i++) { - Optional newDataType = findCommonComplexTypeForCaseWhen(leftFields.get(i).getDataType(), + Optional newDataType = findWiderTypeForTwoForCaseWhen(leftFields.get(i).getDataType(), rightFields.get(i).getDataType()); if (newDataType.isPresent()) { newFields.add(leftFields.get(i).withDataType(newDataType.get()));