kosiew commented on code in PR #18998:
URL: https://github.com/apache/datafusion/pull/18998#discussion_r2591394234


##########
datafusion/datasource-parquet/src/row_filter.rs:
##########
@@ -270,10 +233,12 @@ impl FilterCandidateBuilder {
                 .project(&required_indices_into_table_schema)?,
         );
 
-        let (schema_mapper, projection_into_file_schema) = self
-            .schema_adapter_factory
-            .create(Arc::clone(&projected_table_schema), self.table_schema)
-            .map_schema(&self.file_schema)?;
+        // Compute the projection into the file schema by matching column names
+        let projection_into_file_schema: Vec<usize> = projected_table_schema
+            .fields()
+            .iter()
+            .filter_map(|f| self.file_schema.index_of(f.name()).ok())
+            .collect();

Review Comment:
   3cd7c84b11a94c3fd27884249b37ce4986908c20 is solid regression shield for both 
filter and pruning paths!



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