caicancai commented on code in PR #4172:
URL: https://github.com/apache/calcite/pull/4172#discussion_r1934191023
##########
core/src/main/java/org/apache/calcite/runtime/SqlFunctions.java:
##########
@@ -364,6 +364,21 @@ public static String toHex(ByteString byteString) {
return Hex.encodeHexString(byteString.getBytes());
}
+ /** SQL HEX(varchar) function. */
+ public static String hex(String value) {
+ return Hex.encodeHexString(value.getBytes(UTF_8));
Review Comment:
I'm not sure if it's UTF-8, but I'd accept it if it's compatible with all
tests
--
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]