Uploaded image for project: 'Spark'
  1. Spark
  2. SPARK-40033

Nested schema pruning support through element_at

    XMLWordPrintableJSON

Details

    • Improvement
    • Status: Resolved
    • Major
    • Resolution: Fixed
    • 3.4.0
    • 3.4.0
    • SQL
    • None

    Description

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

      Attachments

        Activity

          People

            ulysses XiDuo You
            ulysses XiDuo You
            Votes:
            0 Vote for this issue
            Watchers:
            3 Start watching this issue

            Dates

              Created:
              Updated:
              Resolved: