YiwenWu commented on code in PR #3684:
URL: https://github.com/apache/calcite/pull/3684#discussion_r1497482552
##########
core/src/main/java/org/apache/calcite/runtime/SqlFunctions.java:
##########
@@ -1491,6 +1491,19 @@ public static String concatMultiWithNull(String... args)
{
public static String concatMultiWithSeparator(String... args) {
// the separator arg could be null
final String sep = args[0] == null ? "" : args[0];
+ return concatMultiWithSeparator(sep, args);
+ }
+
+ /** SQL {@code CONCAT_WS(sep, arg1, arg2, ...)} function,
+ * return null as null sep . */
+ public static @Nullable String concatMultiWithSeparatorNullable(String...
args) {
+ if(args[0] == null){
+ return null;
+ }
+ return concatMultiWithSeparator(args[0], args);
Review Comment:
done
--
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]