cloud-fan commented on code in PR #45064:
URL: https://github.com/apache/spark/pull/45064#discussion_r1482891642


##########
sql/catalyst/src/main/scala/org/apache/spark/sql/catalyst/expressions/codegen/CodeGenerator.scala:
##########
@@ -650,7 +651,7 @@ class CodegenContext extends Logging {
     case FloatType =>
       val clsName = SQLOrderingUtil.getClass.getName.stripSuffix("$")
       s"$clsName.compareFloats($c1, $c2)"
-    // use c1 - c2 may overflow
+    case st: StringType => s"$c1.semanticCompare($c2, ${st.collationId})"

Review Comment:
   shall we still generate java code `$c1.equalsTo($c)` if the string collation 
is UCS_BASIC?



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

Reply via email to