Skip to content

[SPARK-57806][SQL] Fix coercion of NullTyped expressions#56927

Draft
eejbyfeldt wants to merge 1 commit into
apache:masterfrom
eejbyfeldt:SPARK-57806
Draft

[SPARK-57806][SQL] Fix coercion of NullTyped expressions#56927
eejbyfeldt wants to merge 1 commit into
apache:masterfrom
eejbyfeldt:SPARK-57806

Conversation

@eejbyfeldt

Copy link
Copy Markdown
Contributor

What changes were proposed in this pull request?

Instead of replacing the Nulltyped value with a literal a cast is introduced. The optimizer can later constant fold this when that safe to do.

Why are the changes needed?

The current behavior is not safe for expressions that might raise an error as the expression get removed.

Does this PR introduce any user-facing change?

Yes, fixes correctness issue.

How was this patch tested?

Existing a new tests.

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

Generated-by: Claude sonnet 4.6

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