-
Notifications
You must be signed in to change notification settings - Fork 29k
[SPARK-32133][SQL] Forbid time field steps for date start/end in Sequence #28926
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Changes from 1 commit
665ac46
7733184
74c683f
9f910d7
9857fdc
b0eb77f
df2138c
b863eef
9a521a3
2bd2d0b
d860c0e
8c4ffaa
File filter
Filter by extension
Conversations
Jump to
Diff view
Diff view
There are no files selected for viewing
| Original file line number | Diff line number | Diff line change |
|---|---|---|
|
|
@@ -2618,9 +2618,11 @@ object Sequence { | |
| } | ||
|
|
||
| if (stepMonths == 0 && stepMicros == 0 && scale == MICROS_PER_DAY) { | ||
|
Contributor
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. We can probably add comments for each branch. For example, this branch is for adding days to date start/end.
Contributor
Author
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. Done. |
||
| // Adding pure days to date start/end | ||
| backedSequenceImpl.eval(start, stop, fromLong(stepDays)) | ||
|
|
||
| } else if (stepMonths == 0 && stepDays == 0 && scale == 1) { | ||
| // Adding pure microseconds to timestamp start/end | ||
|
Comment on lines
+2621
to
+2625
Contributor
Author
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. @cloud-fan Thanks, I add more comments for pure days and months branch, the former exception check seems the exception content has enough informs, and the last branch seems have detail content. |
||
| backedSequenceImpl.eval(start, stop, fromLong(stepMicros)) | ||
|
|
||
| } else { | ||
|
|
||
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
we can remove this branch now?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Seems we need the
requirecheck in eval, and I removeSPARK-32198branch code from this PR, is it ok ?There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
@TJX2014 . What is SPARK-32198? It's not created yet.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Also, I have the same question like @cloud-fan .
Uh oh!
There was an error while loading. Please reload this page.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
@dongjoon-hyun Sorry, the correct PR is SPARK-31982, this PR is forbid step and the other is cross the timezone.