paul-rogers commented on a change in pull request #1925: DRILL-7472: Fix ser / 
de for sys and information_schema schemas queries
URL: https://github.com/apache/drill/pull/1925#discussion_r356989016
 
 

 ##########
 File path: 
exec/java-exec/src/main/java/org/apache/drill/exec/store/ischema/InfoSchemaGroupScan.java
 ##########
 @@ -111,12 +114,8 @@ public GroupScan clone(List<SchemaPath> columns) {
     return new InfoSchemaGroupScan(this);
   }
 
-  public void setFilterPushedDown(boolean status) {
-    this.isFilterPushedDown = status;
-  }
-
   @JsonIgnore
   public boolean isFilterPushedDown() {
-    return isFilterPushedDown;
+    return filter != null;
 
 Review comment:
   This is tricky. This flag is probably acting more like "has filter push-down 
analysis been done": it prevents Calcite from pushing filters down multiple 
times (which won't work if the group scan removes the original `WHERE` clause 
conditions); and it prevents Calcite from needlessly repeating the analysis 
multiple times when there are no filters.
   
   The proposed change means we will do that no-filter analysis repeatedly.
   
   (As it turns out, I made this same mistake myself in a recent project.)

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

Reply via email to