uros-db commented on code in PR #45643:
URL: https://github.com/apache/spark/pull/45643#discussion_r1549387717
##########
sql/core/src/test/scala/org/apache/spark/sql/CollationStringExpressionsSuite.scala:
##########
@@ -73,17 +74,78 @@ class CollationStringExpressionsSuite extends QueryTest
})
}
+ test("INSTR check result on explicitly collated strings") {
+ def testInStr(str: String, substr: String, collationId: Integer, expected:
Integer): Unit = {
+ val string = Literal.create(str, StringType(collationId))
+ val substring = Literal.create(substr, StringType(collationId))
+
+ checkEvaluation(StringInstr(string, substring), expected)
+ }
+
+ var collationId = CollationFactory.collationNameToId("UTF8_BINARY_LCASE")
Review Comment:
since you have some "UTF8_BINARY" tests down below, consider adding a couple
here as well
--
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]