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/03/30 03:15:48 UTC

[GitHub] [spark] dongjoon-hyun edited a comment on issue #27803: [SPARK-31049][SQL] Support nested adjacent generators, e.g., explode(explode(v))

dongjoon-hyun edited a comment on issue #27803: [SPARK-31049][SQL] Support nested adjacent generators, e.g., explode(explode(v))
URL: https://github.com/apache/spark/pull/27803#issuecomment-605759929
 
 
   BTW, @maropu . After rethinking about this, the approach of this PR looks okay because it works like the following. So, we support more deep invocation if we add more `explode`.
   ```
   scala> sql("select explode(explode(explode(array(array(array(array(1, 2), array(3, 4)))))))").show()
   +------+
   |   col|
   +------+
   |[1, 2]|
   |[3, 4]|
   +------+
   
   
   scala> sql("select explode(explode(explode(explode(array(array(array(array(1, 2), array(3, 4))))))))").show()
   +---+
   |col|
   +---+
   |  1|
   |  2|
   |  3|
   |  4|
   +---+
   ```

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