martin-g commented on code in PR #19890:
URL: https://github.com/apache/datafusion/pull/19890#discussion_r2708371926


##########
datafusion/core/tests/parquet/page_pruning.rs:
##########
@@ -961,3 +964,56 @@ fn cast_count_metric(metric: MetricValue) -> Option<usize> 
{
         _ => None,
     }
 }
+
+#[tokio::test]
+async fn test_parquet_opener_without_page_index() {
+    // Defines a simple schema and batch
+    let schema = Arc::new(Schema::new(vec![Field::new("a", DataType::Int32, 
true)]));
+    let batch = RecordBatch::try_new(
+        schema.clone(),
+        vec![Arc::new(Int32Array::from(vec![1, 2, 3]))],
+    )
+    .unwrap();
+
+    // Create a temp file
+    let file = tempfile::Builder::new()
+        .suffix(".parquet")
+        .tempfile()
+        .unwrap();
+    let path = file.path().to_str().unwrap().to_string();
+
+    // Write parquet WITHOUT page index
+    let props = WriterProperties::builder().build();

Review Comment:
   Which property exactly controls whether the page index is enabled or not ?
   Maybe you can disable it explicitly here with 
`WriterProperties::builder().with_xyz(false).build();`, so it will still work 
as desired if it ever becomes enabled by default.



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


---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]

Reply via email to