fatemehp commented on code in PR #14603:
URL: https://github.com/apache/arrow/pull/14603#discussion_r1035363944


##########
cpp/src/parquet/column_reader.cc:
##########
@@ -337,6 +348,50 @@ void SerializedPageReader::UpdateDecryption(const 
std::shared_ptr<Decryptor>& de
   }
 }
 
+bool SerializedPageReader::ShouldSkipPage(EncodedStatistics& page_statistics) {
+  const PageType::type page_type = LoadEnumSafe(&current_page_header_.type);
+  if (page_type == PageType::DATA_PAGE) {
+    const format::DataPageHeader& header = 
current_page_header_.data_page_header;
+    CheckNumValuesInHeader(header.num_values);
+    page_statistics = ExtractStatsFromHeader(header);

Review Comment:
   ColumnChunkMetadata has is_stats_set(), which should be used to check if the 
statistics are correct, and if yes, set a callback function.



-- 
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]

Reply via email to