liukun4515 commented on code in PR #1977:
URL: https://github.com/apache/arrow-rs/pull/1977#discussion_r911943811
##########
parquet/src/file/serialized_reader.rs:
##########
@@ -248,21 +286,23 @@ impl<R: 'static + ChunkReader> SerializedFileReader<R> {
}
if options.enable_page_index {
- //Todo for now test data `data_index_bloom_encoding_stats.parquet`
only have one rowgroup
- //support multi after create multi-RG test data.
- let cols = metadata.row_group(0);
- let columns_indexes =
- index_reader::read_columns_indexes(&chunk_reader,
cols.columns())?;
- let pages_locations =
- index_reader::read_pages_locations(&chunk_reader,
cols.columns())?;
+ let mut columns_indexes = vec![];
+ let mut offset_indexes = vec![];
+ for rg in &filtered_row_groups {
+ let c = index_reader::read_columns_indexes(&chunk_reader,
rg.columns())?;
+ let p = index_reader::read_pages_locations(&chunk_reader,
rg.columns())?;
+
+ columns_indexes.push(c);
+ offset_indexes.push(p);
Review Comment:
```suggestion
let column_index =
index_reader::read_columns_indexes(&chunk_reader, rg.columns())?;
let offset_index =
index_reader::read_pages_locations(&chunk_reader, rg.columns())?;
columns_indexes.push(c);
offset_indexes.push(p);
```
--
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]