kosiew opened a new issue, #17760:
URL: https://github.com/apache/datafusion/issues/17760

   # 1. Introduce `CastColumnExpr` expression node
   
   * **Goal:** Add a dedicated physical expression for struct-aware casting 
that mirrors the existing `cast_column` helper semantics.
   
   * **Scope & Location:** Implement in `datafusion/physical-expr` (expression 
definition, evaluation logic, scalar/array handling) and expose via the crate’s 
public API.
   
   * **Key Tasks:**
   
     * Define the `CastColumnExpr` struct with schema metadata (input field, 
target field) and implement `PhysicalExpr`.
     * Use `datafusion_common::nested_struct::cast_column` in `evaluate` for 
array and scalar cases, preserving nullability and field ordering.
     * Ensure type coercion rules and `data_type` / `nullable` methods reflect 
the target field accurately.
     * Add unit tests covering basic casts, missing child fields, null-padding, 
and nested structs.
     * Update documentation or module comments describing when to use 
`CastColumnExpr`.
   
   * **Out of Scope:** Any planner/optimizer integration, protobuf wiring, or 
schema-rewriter changes.
   
   


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