hanyuzheng7 commented on code in PR #22785:
URL: https://github.com/apache/flink/pull/22785#discussion_r1242996736
##########
flink-table/flink-table-api-java/src/main/java/org/apache/flink/table/api/internal/BaseExpressions.java:
##########
@@ -1408,6 +1409,24 @@ public OutType arrayUnion(InType array) {
unresolvedCall(ARRAY_UNION, toExpr(),
objectToExpression(array)));
}
+ /**
+ * Returns a string that represents the concatenation of the elements in
the given array and the
+ * elements' data type in the given array is string. The `delimiter` is a
string that separates
+ * each pair of consecutive elements of the array. The optional
`nullReplacement` is a string
+ * that replaces null elements in the array.
+ *
+ * <p>Returns null if input array or delimiter or nullReplacement are null.
+ */
+ public OutType arrayJoin(InType delimiter, InType... nullReplacement) {
Review Comment:
fixed it.
##########
flink-table/flink-table-common/src/main/java/org/apache/flink/table/functions/BuiltInFunctionDefinitions.java:
##########
@@ -285,6 +286,20 @@ ANY, and(logical(LogicalTypeRoot.BOOLEAN), LITERAL)
"org.apache.flink.table.runtime.functions.scalar.ArrayUnionFunction")
.build();
+ public static final BuiltInFunctionDefinition ARRAY_JOIN =
+ BuiltInFunctionDefinition.newBuilder()
+ .name("ARRAY_JOIN")
+ .kind(SCALAR)
+ .inputTypeStrategy(
+ varyingSequence(
+ new
ArrayOfStringArgumentTypeStrategy("ARRAY<STRING>"),
+
logical(LogicalTypeFamily.CHARACTER_STRING),
+
logical(LogicalTypeFamily.CHARACTER_STRING)))
Review Comment:
fixed it.
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: [email protected]
For queries about this service, please contact Infrastructure at:
[email protected]