cloud-fan commented on code in PR #36593:
URL: https://github.com/apache/spark/pull/36593#discussion_r907998198
##########
sql/core/src/main/scala/org/apache/spark/sql/jdbc/H2Dialect.scala:
##########
@@ -41,6 +43,45 @@ private[sql] object H2Dialect extends JdbcDialect {
override def isSupportedFunction(funcName: String): Boolean =
supportedFunctions.contains(funcName)
+ class H2SQLBuilder extends JDBCSQLBuilder {
+ override def visitUserDefinedScalarFunction(
+ funcName: String, canonicalName: String, inputs: Array[String]):
String = {
+ canonicalName match {
+ case "H2.CHAR_LENGTH" =>
Review Comment:
I don't think this makes sense. In production, the H2 dialect does not
expose the `H2.CHAR_LENGTH` UDF. How can it work in a non-test environment?
--
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]
---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]