tanclary commented on code in PR #3286:
URL: https://github.com/apache/calcite/pull/3286#discussion_r1246973446


##########
testkit/src/main/java/org/apache/calcite/test/SqlOperatorTest.java:
##########
@@ -7347,6 +7347,8 @@ private static void 
checkSubstringFunction(SqlOperatorFixture f) {
         "ab", "VARCHAR(3) NOT NULL");
     f.checkString("substring(x'aabbcc' from 1 for 2)",
         "aabb", "VARBINARY(3) NOT NULL");
+    f.checkString("substring('abc' from 2 for 2147483646)",

Review Comment:
   There are already dialect-specific implementations for `SUBSTRING`, perhaps 
we could take advantage of these to specify the operand type to match the 
dialect behavior, and then have different signatures in `SqlFunctions` to 
handle all of the cases. I'll post a similar comment on the case you opened and 
we can keep the discussion going there. Thanks for looking into this!



-- 
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]

Reply via email to