dongjoon-hyun commented on code in PR #46437:
URL: https://github.com/apache/spark/pull/46437#discussion_r1592733398
##########
sql/core/src/main/scala/org/apache/spark/sql/jdbc/JdbcDialects.scala:
##########
@@ -351,7 +351,7 @@ abstract class JdbcDialect extends Serializable with
Logging {
*/
@Since("2.3.0")
protected[jdbc] def escapeSql(value: String): String =
- if (value == null) null else StringUtils.replace(value, "'", "''")
+ if (value == null) null else StringUtils.replace(value, "'", "\\'")
Review Comment:
To @mihailom-db , I believe this is a breaking change which we should not
apply to all JDBCDialect.
If you want to fix something in MySQL, could you isolate it to MySQL only?
> [SPARK-48172][SQL] Fix escaping issue for mysql
--
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]