alamb commented on code in PR #17129: URL: https://github.com/apache/datafusion/pull/17129#discussion_r2269426375
########## datafusion/datasource/src/source.rs: ########## @@ -320,7 +321,39 @@ impl ExecutionPlan for DataSourceExec { &self, projection: &ProjectionExec, ) -> Result<Option<Arc<dyn ExecutionPlan>>> { - self.data_source.try_swapping_with_projection(projection) + match self.data_source.try_swapping_with_projection(projection)? { + Some(new_plan) => { + if let Some(new_data_source_exec) = + new_plan.as_any().downcast_ref::<DataSourceExec>() Review Comment: maybe it is worth making a ticket to track the issue / proposed solution if there is not one already -- 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...@datafusion.apache.org For queries about this service, please contact Infrastructure at: us...@infra.apache.org --------------------------------------------------------------------- To unsubscribe, e-mail: github-unsubscr...@datafusion.apache.org For additional commands, e-mail: github-h...@datafusion.apache.org