Skip to content

[SPARK-55815][SQL] Add proper error class and SQL state for cannotFindCatalogToHandleIdentifierError#54595

Open
miland-db wants to merge 1 commit intoapache:masterfrom
miland-db:milan-dankovic_data/cannot-find-catalog
Open

[SPARK-55815][SQL] Add proper error class and SQL state for cannotFindCatalogToHandleIdentifierError#54595
miland-db wants to merge 1 commit intoapache:masterfrom
miland-db:milan-dankovic_data/cannot-find-catalog

Conversation

@miland-db
Copy link
Contributor

What changes were proposed in this pull request?

This PR adds a proper error class and SQL state for the cannotFindCatalogToHandleIdentifierError exception.

Changes:

  • Added CATALOG_NOT_FOUND_FOR_IDENTIFIER error class to error-conditions.json with SQL state 42000
  • Updated QueryCompilationErrors.cannotFindCatalogToHandleIdentifierError() to use the new error class
  • Removed _LEGACY_ERROR_TEMP_1310 legacy error class

Why are the changes needed?

Previously, this error used _LEGACY_ERROR_TEMP_1310 without a SQL state, making it harder
to identify.

Does this PR introduce any user-facing change?

No.

How was this patch tested?

New tests in DataFrameWriterSuite.scala.

Was this patch authored or co-authored using generative AI tooling?

No.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant