Skip to content

[SPARK-47358][SQL][COLLATION] Improve repeat expression support to return correct datatype#45615

Closed
miland-db wants to merge 10 commits into
apache:masterfrom
miland-db:miland-db/string-repeat-function
Closed

[SPARK-47358][SQL][COLLATION] Improve repeat expression support to return correct datatype#45615
miland-db wants to merge 10 commits into
apache:masterfrom
miland-db:miland-db/string-repeat-function

Conversation

@miland-db
Copy link
Copy Markdown
Contributor

What changes were proposed in this pull request?

Enable collation support for the StringRepeat built-in string function in Spark.

Why are the changes needed?

So we can propagate input string datatype as a result of repeat expression.

Does this PR introduce any user-facing change?

Yes, users will now get different type when using REPEAT on collated strings in Spark SQL queries.

How was this patch tested?

Unit test in CollationStringExpressionsSuite.scala

Was this patch authored or co-authored using generative AI tooling?

No

@github-actions github-actions Bot added the SQL label Mar 20, 2024
Copy link
Copy Markdown
Contributor

@stefankandic stefankandic left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

nit: maybe try formatting your changes (shortcut is option+cmd+l on macos - this will format the entire file, but if you use shift as well you can choose to reformat only uncommitted changes)

@miland-db miland-db force-pushed the miland-db/string-repeat-function branch from c2e8e66 to fd299f9 Compare March 21, 2024 08:44
@miland-db miland-db requested a review from HyukjinKwon March 21, 2024 12:26
@miland-db
Copy link
Copy Markdown
Contributor Author

@MaxGekk @cloud-fan could you please check this and merge it if everything is ok?

@miland-db miland-db requested a review from MaxGekk March 22, 2024 09:47
miland-db and others added 2 commits March 25, 2024 12:22
Co-authored-by: Wenchen Fan <cloud0fan@gmail.com>
@miland-db miland-db requested a review from MaxGekk March 25, 2024 11:24
Copy link
Copy Markdown
Member

@MaxGekk MaxGekk left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Waiting for CI.

@MaxGekk
Copy link
Copy Markdown
Member

MaxGekk commented Mar 26, 2024

The GA's failure is not related to the changes, I believe: Run / Run Spark on Kubernetes Integration test

+1, LGTM. Merging to master.
Thank you, @miland-db and @cloud-fan @stefankandic for review.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

Projects

None yet

Development

Successfully merging this pull request may close these issues.

5 participants