Support Time Parquet Data Page Statistics#11187
Merged
alamb merged 3 commits intoapache:mainfrom Jul 1, 2024
Merged
Conversation
dharanad
commented
Jun 30, 2024
| [<$stat_type_prefix Int32DataPageStatsIterator>]::new($iterator).flatten(), | ||
| )), | ||
| _ => { | ||
| let len = $iterator.count(); |
Contributor
Author
There was a problem hiding this comment.
I have referenced get_statistics macro to decide on returing a null array, my other idea was to conclued with unimplemented!().
Contributor
There was a problem hiding this comment.
You beat me to it ;-).
I think this can just be:
_ => new_empty_array(&DataType::Time32(unit.clone())),And then you need to add new_empty_array into the use statement. Time64 gets a similar treatment.
Contributor
Author
There was a problem hiding this comment.
Much cleaner. Thanks for the idea @efredine
alamb
approved these changes
Jul 1, 2024
| )), | ||
| _ => { | ||
| // don't know how to extract statistics, so return an empty array | ||
| new_empty_array(&DataType::Time32(unit.clone())) |
Contributor
There was a problem hiding this comment.
Technically speaking I think Time32 must be either Seconds or Milliseconds otherwise it is not a valid type.
However, the arrow-rs library doesn't encode this in the types so I think this is a reasonable behavior
findepi
pushed a commit
to findepi/datafusion
that referenced
this pull request
Jul 16, 2024
* add parquet page stats for time * return empty array instead of null * fix typos
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
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
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.
Which issue does this PR close?
Closes #11114
Rationale for this change
What changes are included in this PR?
Are these changes tested?
Covered by existing test cases
Are there any user-facing changes?
No