[ 
https://issues.apache.org/jira/browse/SPARK-40033?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=17577842#comment-17577842
 ] 

Apache Spark commented on SPARK-40033:
--------------------------------------

User 'ulysses-you' has created a pull request for this issue:
https://github.com/apache/spark/pull/37463

> Nested schema pruning support through element_at
> ------------------------------------------------
>
>                 Key: SPARK-40033
>                 URL: https://issues.apache.org/jira/browse/SPARK-40033
>             Project: Spark
>          Issue Type: Improvement
>          Components: SQL
>    Affects Versions: 3.4.0
>            Reporter: XiDuo You
>            Priority: Major
>
> The semantics of element_at is similar with GetArrayItem and GetMapValue, so 
> we can support do nested schema pruning if the inside data type is struct.
> For example:
> For a column schema: `c: array<struct<s1: int, s2: string>>`
> With the query: `SELECT element_at(c, 1).s1`
> The final pruned schema should be `c: array<struct<s1: int>>`



--
This message was sent by Atlassian Jira
(v8.20.10#820010)

---------------------------------------------------------------------
To unsubscribe, e-mail: issues-unsubscr...@spark.apache.org
For additional commands, e-mail: issues-h...@spark.apache.org

Reply via email to