[Vectorized](function) support topn_array function (#13869)

This commit is contained in:
zhangstar333
2022-11-02 19:49:23 +08:00
committed by GitHub
parent b26d8f284c
commit 374303186c
15 changed files with 482 additions and 176 deletions

View File

@ -2466,6 +2466,13 @@ public class FunctionSet<T> {
"", "", "", "", "", true, false, true, true));
addBuiltin(AggregateFunction.createBuiltin(COLLECT_SET, Lists.newArrayList(t), new ArrayType(t), t,
"", "", "", "", "", true, false, true, true));
addBuiltin(
AggregateFunction.createBuiltin("topn_array", Lists.newArrayList(t, Type.INT), new ArrayType(t), t,
"", "", "", "", "", true, false, true, true));
addBuiltin(
AggregateFunction
.createBuiltin("topn_array", Lists.newArrayList(t, Type.INT, Type.INT), new ArrayType(t), t,
"", "", "", "", "", true, false, true, true));
}
// Avg

View File

@ -158,6 +158,8 @@ public abstract class Type {
arraySubTypes.add(DECIMALV2);
arraySubTypes.add(DATE);
arraySubTypes.add(DATETIME);
arraySubTypes.add(DATEV2);
arraySubTypes.add(DATETIMEV2);
arraySubTypes.add(CHAR);
arraySubTypes.add(VARCHAR);
arraySubTypes.add(STRING);