You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@doris.apache.org by mo...@apache.org on 2022/12/28 14:38:06 UTC

[doris] branch branch-1.2-lts updated: [Bug](function) forbid hll_union input not hll type param (#15397)

This is an automated email from the ASF dual-hosted git repository.

morningman pushed a commit to branch branch-1.2-lts
in repository https://gitbox.apache.org/repos/asf/doris.git


The following commit(s) were added to refs/heads/branch-1.2-lts by this push:
     new 319f65fd06 [Bug](function) forbid hll_union input not hll type param (#15397)
319f65fd06 is described below

commit 319f65fd0604859a483d33e571506deb3f54f2b3
Author: Pxl <px...@qq.com>
AuthorDate: Wed Dec 28 12:23:34 2022 +0800

    [Bug](function) forbid hll_union input not hll type param (#15397)
    
    forbid hll_union input not hll type param
---
 .../main/java/org/apache/doris/analysis/FunctionCallExpr.java | 11 ++++++-----
 1 file changed, 6 insertions(+), 5 deletions(-)

diff --git a/fe/fe-core/src/main/java/org/apache/doris/analysis/FunctionCallExpr.java b/fe/fe-core/src/main/java/org/apache/doris/analysis/FunctionCallExpr.java
index 59d8fbc8f1..29a8a3deae 100644
--- a/fe/fe-core/src/main/java/org/apache/doris/analysis/FunctionCallExpr.java
+++ b/fe/fe-core/src/main/java/org/apache/doris/analysis/FunctionCallExpr.java
@@ -801,12 +801,13 @@ public class FunctionCallExpr extends Expr {
             }
         }
 
-        if ((fnName.getFunction().equalsIgnoreCase(FunctionSet.HLL_UNION_AGG)
-                || fnName.getFunction().equalsIgnoreCase(FunctionSet.HLL_CARDINALITY)
-                || fnName.getFunction().equalsIgnoreCase(FunctionSet.HLL_RAW_AGG))
+        if ((fnName.getFunction().equalsIgnoreCase("HLL_UNION_AGG")
+                || fnName.getFunction().equalsIgnoreCase("HLL_CARDINALITY")
+                || fnName.getFunction().equalsIgnoreCase("HLL_RAW_AGG")
+                || fnName.getFunction().equalsIgnoreCase("HLL_UNION"))
                 && !arg.type.isHllType()) {
             throw new AnalysisException(
-                    "HLL_UNION_AGG, HLL_RAW_AGG and HLL_CARDINALITY's params must be hll column");
+                    "HLL_UNION, HLL_UNION_AGG, HLL_RAW_AGG and HLL_CARDINALITY's params must be hll column");
         }
 
         if (fnName.getFunction().equalsIgnoreCase("min")
@@ -815,7 +816,7 @@ public class FunctionCallExpr extends Expr {
         } else if (fnName.getFunction().equalsIgnoreCase("DISTINCT_PC")
                 || fnName.getFunction().equalsIgnoreCase("DISTINCT_PCSA")
                 || fnName.getFunction().equalsIgnoreCase("NDV")
-                || fnName.getFunction().equalsIgnoreCase(FunctionSet.HLL_UNION_AGG)) {
+                || fnName.getFunction().equalsIgnoreCase("HLL_UNION_AGG")) {
             fnParams.setIsDistinct(false);
         }
 


---------------------------------------------------------------------
To unsubscribe, e-mail: commits-unsubscribe@doris.apache.org
For additional commands, e-mail: commits-help@doris.apache.org