metesynnada commented on code in PR #9080:
URL: https://github.com/apache/arrow-datafusion/pull/9080#discussion_r1474012440


##########
datafusion/physical-plan/src/joins/sort_merge_join.rs:
##########
@@ -1067,18 +1096,40 @@ impl SMJStream {
                 .collect::<Result<Vec<_>, ArrowError>>()
                 .map_err(Into::<DataFusionError>::into)?;
 
+            // Create null streamed (left) columns
             let mut streamed_columns = self
                 .streamed_schema
                 .fields()
                 .iter()
                 .map(|f| new_null_array(f.data_type(), buffered_indices.len()))
                 .collect::<Vec<_>>();
 
+            let filter_columns =

Review Comment:
   Inside `get_filter_column`, the filter is checked if it is `Some`.  If not, 
the result will be an empty vector.
   
   Instead of doing that, you can move the filter columns calculation under 
   `let output_batch = if let Some(f) = &self.filter {` and make 
`get_filter_column` expects `joinfilter_filter: &JoinFilter`. 



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