Commits


Will Jones authored and GitHub committed 8732b278580
GH-34546: [C++] Support casting from large string to string scalar (#34549) ### Rationale for this change We rely on scalar casting to create partition values. Some systems, such as Polars, always use LargeString arrays instead of String, so we need to make sure we can handle those partition values correctly. ### What changes are included in this PR? Adds casting function for `LargeStringScalar` and `LargeBinaryScalar` to `StringScalar`. Tests that we correctly format Hive partition values for large string. ### Are these changes tested? The casting functions are implicitly tested in other places (like the test added). There are no existing tests for `CastTo` for binary/string scalars. ### Are there any user-facing changes? Fixes a bug. I guess it is a breaking change, given that Ruby was testing that the serialized value of a LargeBinaryScalar was `"[\n{value}\n]"`. But I don't think that was actually something anyone really wanted, was it? * Closes: #34546 Authored-by: Will Jones <willjones127@gmail.com> Signed-off-by: Will Jones <willjones127@gmail.com>