ilicmarkodb opened a new pull request, #54608:
URL: https://github.com/apache/spark/pull/54608
### What changes were proposed in this pull request?
Rename the legacy error class `_LEGACY_ERROR_TEMP_1034` to
`WINDOW_FUNCTION_NOT_ALLOWED_IN_CLAUSE` and add SQL state `42601`.
This error is thrown when a user uses window functions inside a WHERE or
HAVING clause, which is not allowed by the SQL standard.
### Why are the changes needed?
Legacy error classes with temporary names (`_LEGACY_ERROR_TEMP_*`) are being
migrated to proper descriptive names as part of the ongoing error framework
improvements. Adding a SQL state makes the error easier to identify and handle
programmatically.
### Does this PR introduce _any_ user-facing change?
No behavioral change. The error message remains identical. Only the error
class name and SQL state metadata are updated.
### How was this patch tested?
Existing golden file tests (`pipe-operators.sql.out`,
`window_part3.sql.out`) already cover this error and have been updated with the
new error class name and SQL state.
### Was this patch authored or co-authored using generative AI tooling?
Yes, co-authored with Claude Code.
--
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]