You are viewing a plain text version of this content. The canonical link for it is here.
Posted to reviews@spark.apache.org by GitBox <gi...@apache.org> on 2020/02/24 19:16:16 UTC

[GitHub] [spark] peter-toth commented on a change in pull request #27675: [SPARK-30870][SQL] Column pruning shouldn't alias a nested column if it means the whole structure

peter-toth commented on a change in pull request #27675: [SPARK-30870][SQL] Column pruning shouldn't alias a nested column if it means the whole structure
URL: https://github.com/apache/spark/pull/27675#discussion_r383460910
 
 

 ##########
 File path: sql/catalyst/src/test/scala/org/apache/spark/sql/catalyst/optimizer/NestedColumnAliasingSuite.scala
 ##########
 @@ -215,12 +215,7 @@ class NestedColumnAliasingSuite extends SchemaPruningTest {
 
     val optimized = Optimize.execute(query)
 
-    val expected = nestedRelation
-      .select(GetStructField('a, 0, Some("b")))
-      .limit(5)
-      .analyze
-
-    comparePlans(optimized, expected)
+    comparePlans(optimized, query)
 
 Review comment:
   @dongjoon-hyun hmm, does this test have anything to do with limit push down? There is no `LimitPushDown` is the optimizer of this suite: https://github.com/apache/spark/blob/5a51b9472f5dfbf99ef6f8d6c7151618157c446e/sql/catalyst/src/test/scala/org/apache/spark/sql/catalyst/optimizer/NestedColumnAliasingSuite.scala#L34-L39 and actually `limit` is closer to the relation in the original `query` than in `expected`, but I might be wrong.

----------------------------------------------------------------
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:
users@infra.apache.org


With regards,
Apache Git Services

---------------------------------------------------------------------
To unsubscribe, e-mail: reviews-unsubscribe@spark.apache.org
For additional commands, e-mail: reviews-help@spark.apache.org