panbingkun commented on code in PR #46969:
URL: https://github.com/apache/spark/pull/46969#discussion_r1637891385
##########
sql/core/src/main/scala/org/apache/spark/sql/jdbc/OracleDialect.scala:
##########
@@ -229,6 +231,24 @@ private case class OracleDialect() extends JdbcDialect
with SQLConfHelper {
override def supportsLimit: Boolean = true
override def supportsOffset: Boolean = true
+
+ override def classifyException(
+ e: Throwable,
+ errorClass: String,
+ messageParameters: Map[String, String],
+ description: String): AnalysisException = {
+ e match {
+ case sqlException: SQLException =>
+ logSQLException(sqlException, errorClass, messageParameters,
description)
+ sqlException.getErrorCode match {
+ case 955 if errorClass == "FAILED_JDBC.RENAME_TABLE" =>
Review Comment:
ref:
```
errorCode: 955, sqlState: 42000, message: ORA-00955: name is already used by
an existing object
https://docs.oracle.com/error-help/db/ora-00955/, errorClass:
FAILED_JDBC.RENAME_TABLE, messageParameters: Map(url ->
jdbc:oracle:thin:system/Th1s1sThe0racle#Pass@//10.1.0.20:38407/freepdb1,
oldName -> `tbl2`, newName -> `tbl1`),description: Failed table renaming from
tbl2 to tbl1
```
--
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]