Commits


Thomas Newton authored and GitHub committed c14d55d99f3
GH-44555: [C++][Compute] Allow casting struct to bigger nullable struct (#44587) ### Rationale for this change Sometimes its useful to add a column full of nulls in a cast. Currently this is supported in top level columns but not inside structs. Example where this is important: https://github.com/delta-io/delta-rs/issues/1610 ### What changes are included in this PR? Add support for filling in columns full of null for nullable struct fields. I've gone for a fairly minimal change that achieves what I needed but I wonder if there should be a more significant change so that this casting is done by field name and ignore the field order. ### Are these changes tested? Yes. The expected behaviour in several existing tests has been altered and a couple of new tests have been added. I also rolled out a custom build with this change internally because it suddenly became a critical problem. ### Are there any user-facing changes? Yes. There are scenarios that previously failed with `struct fields don't match or are in the wrong order` but now succeed after filling in `null`s. * GitHub Issue: #44555 Lead-authored-by: Thomas Newton <thomas.w.newton@gmail.com> Co-authored-by: David Li <li.davidm96@gmail.com> Signed-off-by: David Li <li.davidm96@gmail.com>