Github user gatorsmile commented on a diff in the pull request:

    https://github.com/apache/spark/pull/11828#discussion_r56869818
  
    --- Diff: 
sql/catalyst/src/test/scala/org/apache/spark/sql/catalyst/optimizer/ColumnPruningSuite.scala
 ---
    @@ -297,7 +302,7 @@ class ColumnPruningSuite extends PlanTest {
                 SortOrder('b, Ascending) :: Nil,
                 UnspecifiedFrame)).as('window) :: Nil,
               'a :: Nil, 'b.asc :: Nil)
    -        .select('a, 'c, 'window).where('window > 1).select('a, 'c).analyze
    +        .where('window > 1).select('a, 'c).analyze
    --- End diff --
    
    If so, it becomes harder for Optimizer to judge which plan is better. Based 
on my understanding, the general principle of `ColumnPruning` is doing the best 
to add extra `Project` or pushing `Project` down as deep as possible. Could you 
explain the current strategy for this rule? We might need to add more test 
cases to check if it does the desired work.


---
If your project is set up for it, you can reply to this email and have your
reply appear on GitHub as well. If your project does not have this feature
enabled and wishes so, or if the feature is enabled but not working, please
contact infrastructure at [email protected] or file a JIRA ticket
with INFRA.
---

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

Reply via email to