Skip to content

fix: handle Utf8View and LargeUtf8 separators in concat_ws#20361

Open
neilconway wants to merge 1 commit intoapache:mainfrom
neilconway:neilc/concat-ws-string-types
Open

fix: handle Utf8View and LargeUtf8 separators in concat_ws#20361
neilconway wants to merge 1 commit intoapache:mainfrom
neilconway:neilc/concat-ws-string-types

Conversation

@neilconway
Copy link
Contributor

Which issue does this PR close?

Rationale for this change

concat_ws only handled Utf8 separators (despite its signature claiming otherwise). Attempting to pass a Utf8View or LargeUtf8 separator would result in a panic or internal error.

What changes are included in this PR?

  • Add SLT test case for array Utf8View separator
  • Add unit test for scalar Utf8View separator
  • Fix behavior: add support for LargeUtf8 and Utf8View separators, both array and scalar
  • Other minor code cleanups and improvements

Are these changes tested?

Yes. Added new test cases.

Note that we can't easily the scalar separator case via SQL, because simplify_concat_ws happens to cast constant/scalar separators to Utf8. That behavior is dubious and should be changed, but I'll tackle that in a subsequent PR.

Are there any user-facing changes?

No, aside from a previously failing query now succeeding.

@github-actions github-actions bot added sqllogictest SQL Logic Tests (.slt) functions Changes to functions implementation labels Feb 15, 2026
concat_ws only handled Utf8 separators; attempting to pass a Utf8View or
LargeUtf8 separator would result in a panic or error.
@neilconway neilconway force-pushed the neilc/concat-ws-string-types branch from c9d3bcf to b68b354 Compare February 15, 2026 02:41
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

functions Changes to functions implementation sqllogictest SQL Logic Tests (.slt)

Projects

None yet

Development

Successfully merging this pull request may close these issues.

concat_ws() fails with Utf8View, LargeUtf8 separators

1 participant