rohangarg commented on code in PR #14237:
URL: https://github.com/apache/druid/pull/14237#discussion_r1190672026


##########
processing/src/main/java/org/apache/druid/segment/join/JoinableFactoryWrapper.java:
##########
@@ -178,15 +183,37 @@ static JoinClauseToFilterConversion convertJoinToFilter(
         }
 
         numValues -= columnValuesWithUniqueFlag.getColumnValues().size();
-        filters.add(Filters.toFilter(new InDimFilter(leftColumn, 
columnValuesWithUniqueFlag.getColumnValues())));
+        // For each column value which are received in order we increment the 
index
+        // and add it in the appropriate index in the map
+        int c = 0;
+        for (String val : columnValuesWithUniqueFlag.getColumnValues()) {

Review Comment:
   I think if we currently pass the filter as `C1 IN (A, B) AND C2 IN (C, D)`, 
what we actually need is `(C1, C2) IN ((A, C), (B, D))`.
   So, maybe we could pass the in filters down since `(A, C)` and `(B,D)` both 
satisfy `C1 IN (A, B) AND C2 IN (C, D)` - the join condition could filter more 
after the in filters to extract only `(A, C)` and `(B, D)` and eliminate tuples 
like `(A, D)` and `(B, C)`.



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