andygrove opened a new issue, #5125:
URL: https://github.com/apache/datafusion-comet/issues/5125

   ### What is the problem the feature request solves?
   
   `GenerateExec` runs natively for `explode` and `posexplode` over arrays, but 
the `inline` and `stack` generators fall back to Spark, taking the surrounding 
stage with them.
   
   Flattening nested data is a staple of ETL over semi-structured sources: 
`inline` is the idiomatic way to expand an array of structs into columns, and 
`stack` is the standard unpivot. Both commonly appear directly above a Parquet 
scan, so the fallback lands on exactly the stages Comet otherwise accelerates 
well.
   
   ### Describe the potential solution
   
   - `inline(array<struct>)` is `explode` followed by flattening the struct 
fields into top-level columns, so it should be able to reuse the existing 
native explode machinery plus a projection.
   - `stack(n, expr1, ..., exprk)` is a constant-shape row expansion and does 
not depend on array input at all.
   
   `explode_outer` support is tracked separately in #2838; the `_outer` 
variants of `inline` would follow the same null-row semantics.
   
   ### Additional context
   
   Related: #2838 (`explode_outer`), #4269 (added `posexplode` / 
`posexplode_outer`).
   


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

To unsubscribe, e-mail: [email protected]

For queries about this service, please contact Infrastructure at:
[email protected]


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

Reply via email to