pitrou commented on code in PR #46532: URL: https://github.com/apache/arrow/pull/46532#discussion_r2101866165
########## cpp/src/parquet/column_reader.cc: ########## @@ -2069,11 +2070,35 @@ class ByteArrayChunkedRecordReader final : public TypedRecordReader<ByteArrayTyp virtual public BinaryRecordReader { public: ByteArrayChunkedRecordReader(const ColumnDescriptor* descr, LevelInfo leaf_info, - ::arrow::MemoryPool* pool, bool read_dense_for_nullable) + ::arrow::MemoryPool* pool, bool read_dense_for_nullable, + std::shared_ptr<::arrow::DataType> arrow_type) : TypedRecordReader<ByteArrayType>(descr, leaf_info, pool, read_dense_for_nullable) { ARROW_DCHECK_EQ(descr_->physical_type(), Type::BYTE_ARRAY); - accumulator_.builder = std::make_unique<::arrow::BinaryBuilder>(pool); + auto arrow_binary_type = arrow_type ? arrow_type->id() : ::arrow::Type::BINARY; Review Comment: Given that `arrow_type` is a new optional parameter, I suppose it could. If we decide that `RecordReader` is only an internal API, we can probably remove the fallback, but it doesn't complicate the code much in any case. -- 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: github-unsubscr...@arrow.apache.org For queries about this service, please contact Infrastructure at: us...@infra.apache.org