jiwen624 commented on code in PR #56998:
URL: https://github.com/apache/spark/pull/56998#discussion_r3547422988


##########
sql/catalyst/src/main/scala/org/apache/spark/sql/catalyst/expressions/regexpExpressions.scala:
##########
@@ -1150,10 +1152,11 @@ case class RegExpInStr(subject: Expression, regexp: 
Expression, idx: Expression)
       s"""
          |try {
          |  $setEvNotNull
-         |  ${RegExpUtils.initLastMatcherCode(ctx, subject, regexp, matcher, 
prettyName,
+         |  String $source = $subject.toString();
+         |  ${RegExpUtils.initLastMatcherCode(ctx, source, regexp, matcher, 
prettyName,

Review Comment:
   @sarutak thanks for the review! 👍  the comments are addressed.



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