jon-wei commented on a change in pull request #9373: Fix join filter push down 
post-join virtual column handling
URL: https://github.com/apache/druid/pull/9373#discussion_r381520134
 
 

 ##########
 File path: 
processing/src/main/java/org/apache/druid/segment/join/HashJoinSegmentStorageAdapter.java
 ##########
 @@ -234,13 +235,17 @@ public Metadata getMetadata()
       // Virtual columns cannot depend on each other, so we don't need to 
check transitive dependencies.
       if (baseColumns.containsAll(virtualColumn.requiredColumns())) {
         preJoinVirtualColumns.add(virtualColumn);
+        // Since pre-join virtual columns can be computed using only base 
columns, we include them in the
+        // base column set.
+        baseColumns.add(virtualColumn.getOutputName());
 
 Review comment:
   This case is covered by 
`JoinFilterAnalyzerTest.test_filterPushDown_factToRegionToCountryLeftFilterOnChannelVirtualColumn`

----------------------------------------------------------------
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.
 
For queries about this service, please contact Infrastructure at:
[email protected]


With regards,
Apache Git Services

---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]

Reply via email to