urosstan-db commented on code in PR #53456:
URL: https://github.com/apache/spark/pull/53456#discussion_r2614007752


##########
sql/core/src/main/scala/org/apache/spark/sql/jdbc/JdbcDialects.scala:
##########
@@ -783,7 +783,9 @@ abstract class JdbcDialect extends Serializable with 
Logging {
   }
 
   @Since("4.1.0")
-  def isObjectNotFoundException(e: SQLException): Boolean = true
+  def isObjectNotFoundException(e: SQLException): Option[Boolean] = {
+    isSyntaxErrorBestEffort(e)

Review Comment:
   Let's put default to be sqlState startsWith 42 (like 42000, 42016, etc). 
Even error code may be insufficient access privilege, or syntax error, we 
should be fine (since no access == no table for current user), while syntax 
error should not happen, since we execute very simple queries to find table.



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