Skip to content

Conversation

@LuciferYang
Copy link
Contributor

@LuciferYang LuciferYang commented Dec 12, 2022

What changes were proposed in this pull request?

This pr aims to reuse error class INVALID_TYPED_LITERAL instead of _LEGACY_ERROR_TEMP_1020.

Why are the changes needed?

Proper names of error classes to improve user experience with Spark SQL.

Does this PR introduce any user-facing change?

No

How was this patch tested?

Pass Github Actions.

@LuciferYang LuciferYang marked this pull request as draft December 12, 2022 01:56
@github-actions github-actions bot added the SQL label Dec 12, 2022
@github-actions github-actions bot added the CORE label Dec 12, 2022
@LuciferYang LuciferYang changed the title [SPARK-41481][CORE][SQL] Reuse INVALID_TYPED_LITERAL instead of _LEGACY_ERROR_TEMP_1020 [SPARK-41481][CORE][SQL] Reuse INVALID_TYPED_LITERAL instead of _LEGACY_ERROR_TEMP_0020 Dec 12, 2022
@github-actions github-actions bot removed the CORE label Dec 12, 2022
@github-actions github-actions bot added the CORE label Dec 12, 2022
} catch {
case e: IllegalArgumentException =>
val ex = QueryParsingErrors.cannotParseIntervalValueError(value, ctx)
val ex = QueryParsingErrors.cannotParseValueTypeError(valueType, value, ctx)
Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

@MaxGekk do you think the valueType use INTERVAL is OK?

Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I think, it is ok.

} catch {
case e: IllegalArgumentException =>
val ex = QueryParsingErrors.cannotParseIntervalValueError(value, ctx)
val ex = QueryParsingErrors.cannotParseValueTypeError(valueType, value, ctx)
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I think, it is ok.

@MaxGekk
Copy link
Member

MaxGekk commented Dec 12, 2022

@LuciferYang Is it ready?

@LuciferYang LuciferYang marked this pull request as ready for review December 13, 2022 03:38
@LuciferYang
Copy link
Contributor Author

ready now

@MaxGekk
Copy link
Member

MaxGekk commented Dec 13, 2022

+1, LGTM. Merging to master.
Thank you, @LuciferYang.

@MaxGekk MaxGekk closed this in 9b69331 Dec 13, 2022
@LuciferYang
Copy link
Contributor Author

Thanks @MaxGekk

beliefer pushed a commit to beliefer/spark that referenced this pull request Dec 18, 2022
…EGACY_ERROR_TEMP_0020`

### What changes were proposed in this pull request?
This pr aims to reuse error class `INVALID_TYPED_LITERAL` instead of `_LEGACY_ERROR_TEMP_1020`.

### Why are the changes needed?
Proper names of error classes to improve user experience with Spark SQL.

### Does this PR introduce _any_ user-facing change?
No

### How was this patch tested?
Pass Github Actions.

Closes apache#39025 from LuciferYang/SPARK-41481.

Authored-by: yangjie01 <[email protected]>
Signed-off-by: Max Gekk <[email protected]>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants