Light-City commented on code in PR #41122:
URL: https://github.com/apache/arrow/pull/41122#discussion_r1559640025


##########
cpp/src/arrow/acero/swiss_join.cc:
##########
@@ -2160,6 +2160,9 @@ Status JoinResidualFilter::FilterOneBatch(const 
ExecBatch& keypayload_batch,
                                           bool output_key_ids, bool 
output_payload_ids,
                                           arrow::util::TempVectorStack* 
temp_stack,
                                           int* num_passing_rows) const {
+  if (num_batch_rows == 0) {

Review Comment:
   detail case:
   ```
   gpadmin=# select * from stu;
    id | name | age 
   ----+------+-----
     2 | hack |  28
   (1 row)
   
   gpadmin=# select * from score;
    id | stu_id | subject | score 
   ----+--------+---------+-------
     1 |     10 | Jack    |    95
     2 |     10 | Jack    |    98
     3 |     12 | math    |    97
     4 |     15 | TOM     |    92
   (4 rows)
   ```
   
   SELECT * FROM stu st WHERE NOT  EXISTS (SELECT stu_id FROM score 
   where score.stu_id = st.id and st.age>25);
   
   FilterLeftSemi will got **num_batch_rows=0**



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