pitrou commented on code in PR #35989:
URL: https://github.com/apache/arrow/pull/35989#discussion_r1234041242


##########
cpp/src/parquet/column_writer.cc:
##########
@@ -1346,7 +1346,12 @@ class TypedColumnWriterImpl : public ColumnWriterImpl, 
public TypedColumnWriter<
 
   EncodedStatistics GetChunkStatistics() override {
     EncodedStatistics result;
-    if (chunk_statistics_) result = chunk_statistics_->Encode();
+    if (chunk_statistics_) {
+      if (has_dictionary_ && !fallback_) {
+        
chunk_statistics_->SetDistinctCount(current_dict_encoder_->num_entries());

Review Comment:
   I _think_ it's ok. But I don't think it's very important to write the 
distinct count, if we're only able to write it for dictionary-encoded chunks.



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