Skip to content

Conversation

@iRakson
Copy link
Contributor

@iRakson iRakson commented Nov 14, 2019

What changes were proposed in this pull request?

cast to float behaviour in SparkSQL is made consistent with PostgreSQL when spark.sql.dialect is set to PostgreSQL.

Why are the changes needed?

SparkSQL and PostgreSQL behaviour is very different when casting to float.
For e.g:
select cast('abc' to float) in SparkSQL gives null.
select cast('abc' to float) in PostgreSQL gives "invalid input syntax for type double precision"

Does this PR introduce any user-facing change?

Yes

How was this patch tested?

Manually tested. Test cases will be added soon.

@AmplabJenkins
Copy link

Can one of the admins verify this patch?

@maropu
Copy link
Member

maropu commented Nov 15, 2019

Just added the link for tracking: #26518 (comment)

@dongjoon-hyun
Copy link
Member

Thank you for contribution, @iRakson . But, unfortunately, we decided to remove PostgreSQL dialect via SPARK-30125 (#26763). Sorry about that. I'll close this PR, too.

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.

4 participants