ILuffZhe commented on code in PR #4431:
URL: https://github.com/apache/calcite/pull/4431#discussion_r2161497204
##########
testkit/src/main/java/org/apache/calcite/test/SqlOperatorTest.java:
##########
@@ -2565,6 +2568,17 @@ private static void checkConcatFunc(SqlOperatorFixture
f) {
f.checkString("concat('', '', 'a')", "a", "VARCHAR(1) NOT NULL");
f.checkString("concat('', '', '')", "", "VARCHAR(0) NOT NULL");
f.checkFails("^concat()^", INVALID_ARGUMENTS_NUMBER, false);
+
+ // test for ByteString
+ f.checkString("concat(x'61',x'62')", "0x6162", "VARCHAR(2) NOT NULL");
+ f.checkString("concat(cast(x'61' as binary), cast(x'62' as binary), "
+ + "cast(x'63' as binary))", "0x616263", "VARCHAR(3) NOT NULL");
Review Comment:
I'm not sure if changing it to VARCHAR_NULLABLE is suitable, can we get
binary's precision in ReturnTypes?
--
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]