[ 
https://issues.apache.org/jira/browse/SPARK-29840?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel
 ]

Dongjoon Hyun updated SPARK-29840:
----------------------------------
    Affects Version/s:     (was: 3.0.0)
                       3.1.0

> PostgreSQL dialect: cast to integer
> -----------------------------------
>
>                 Key: SPARK-29840
>                 URL: https://issues.apache.org/jira/browse/SPARK-29840
>             Project: Spark
>          Issue Type: Sub-task
>          Components: SQL
>    Affects Versions: 3.1.0
>            Reporter: jobit mathew
>            Priority: Major
>
> Make SparkSQL's cast to integer  behavior be consistent with PostgreSQL when 
> spark.sql.dialect is configured as PostgreSQL.
> Example:*currently spark sql*
> {code:java}
> spark-sql> select   CAST ('10C' AS INTEGER);
> NULL
> Time taken: 0.051 seconds, Fetched 1 row(s)
> spark-sql>
> {code}
> *postgresql*
> {code:java}
> postgresql
> select   CAST ('10C' AS INTEGER);
> Error(s), warning(s):
> 22P02: invalid input syntax for integer: "10C"
> {code}



--
This message was sent by Atlassian Jira
(v8.3.4#803005)

---------------------------------------------------------------------
To unsubscribe, e-mail: issues-unsubscr...@spark.apache.org
For additional commands, e-mail: issues-h...@spark.apache.org

Reply via email to