mapleFU commented on code in PR #4326:
URL: https://github.com/apache/arrow-rs/pull/4326#discussion_r1213087653
##########
parquet/src/column/page.rs:
##########
@@ -277,18 +278,27 @@ impl TryFrom<&PageHeader> for PageMetadata {
fn try_from(value: &PageHeader) -> std::result::Result<Self, Self::Error> {
match value.type_ {
- crate::format::PageType::DATA_PAGE => Ok(PageMetadata {
- num_rows: value.data_page_header.as_ref().unwrap().num_values
as usize,
- is_dict: false,
- }),
+ crate::format::PageType::DATA_PAGE => {
+ let header = value.data_page_header.as_ref().unwrap();
+ Ok(PageMetadata {
+ num_rows: None,
+ num_levels: Some(header.num_values as _),
Review Comment:
I guess when page `max_def_level == 0`, `num_values` doesn't means
`num_levels`?
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: [email protected]
For queries about this service, please contact Infrastructure at:
[email protected]