-
Notifications
You must be signed in to change notification settings - Fork 29k
[SPARK-28420][SQL] Support the INTERVAL type in date_part()
#25981
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
Closed
Closed
Changes from 1 commit
Commits
Show all changes
43 commits
Select commit
Hold shift + click to select a range
b75a80f
Add Millennium
MaxGekk b233c90
Add Century
MaxGekk 6f017a6
Add Decade
MaxGekk ac1c3a8
Add Year
MaxGekk 7265508
Add Quarter
MaxGekk 554df71
Move MONTHS_PER_QUARTER up
MaxGekk d0f89f4
Eliminate a warning
MaxGekk 8174fd5
Extend with ExpectsInputTypes
MaxGekk 6378b95
Remove blank lines
MaxGekk 8e4ca7d
Add Month
MaxGekk 8ed01c7
Week is not supported by PostgreSQL
MaxGekk f1eea12
Remove not-supported fields
MaxGekk 561f789
Week of interval is not supported
MaxGekk 0a671a9
Add Day
MaxGekk 894a6c7
Add Hour
MaxGekk f86f4f5
Change Month type to ByteType
MaxGekk 283fd99
Change Quarter type to ByteType
MaxGekk 5e189ca
Put common code to IntervalPart
MaxGekk 62c21b9
Run scalafmt
MaxGekk a4fbb5e
Add Minute
MaxGekk e1c9415
Add Second
MaxGekk 7f4100f
Run scalafmt
MaxGekk f3cf7f0
Refactoring
MaxGekk 9262f9d
Add a test for overflow
MaxGekk b9890ec
Add Milliseconds
MaxGekk bea3faf
Add Microseconds
MaxGekk 77e0fb3
Add Epoch
MaxGekk 58017a7
Support intervals by date_part
MaxGekk f5620b3
Update comments for DatePart
MaxGekk dcaf5b2
Regenerate results of date_part.sql
MaxGekk f202b15
Add tests for intervals to date_part.sql
MaxGekk dca29e5
Remove wrong test
MaxGekk f8a2385
Make Dongjoon and Scala style checker happy
MaxGekk 7b1663e
Merge remote-tracking branch 'remotes/origin/master' into extract-fro…
MaxGekk 8a494a2
Improve an example
MaxGekk f08531b
Precise epoch calculation from intervals
MaxGekk e8a61c8
Fix expected results in IntervalExpressionsSuite
MaxGekk f8a45b3
Revert "Precise epoch calculation from intervals"
MaxGekk a496d73
Precise calculation micros per month
MaxGekk 47a0290
Revert "Precise calculation micros per month"
MaxGekk 2099a91
Fix expected results in IntervalExpressionsSuite
MaxGekk d4375b5
Add the Extract prefix to all classes
MaxGekk 5620472
Change indentation for extends to 2 spaces
MaxGekk File filter
Filter by extension
Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Eliminate a warning
- Loading branch information
commit d0f89f41a6543659e533eba22f599e3f7c7dc0f5
There are no files selected for viewing
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
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.
ditto. Let's remove the
intervaldirectory and move this suite to the parent directory.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.
I moved the interval related expressions to the separate package to not clash to date-time expressions. Though I renamed interval expressions in f3cf7f0 but having
MillenniumandMillenniumsin the same name space looks confusing, doesn't it?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.
New changes look better to me.