Uploaded image for project: 'Spark'
  1. Spark
  2. SPARK-28589 Introduce a new type coercion mode by following PostgreSQL
  3. SPARK-28512

New optional mode: throw runtime exceptions on casting failures

    XMLWordPrintableJSON

Details

    • Sub-task
    • Status: Resolved
    • Major
    • Resolution: Fixed
    • 3.0.0
    • 3.0.0
    • SQL
    • None

    Description

      In popular DBMS like MySQL/PostgreSQL/Oracle, runtime exceptions are thrown on casting, e.g. cast('abc' as boolean)
      While in Spark, the result is converted as null silently. It is by design since we don't want a long-running job aborted by some casting failure. But there are scenarios that users want to make sure all the data conversion are correct, like the way they use MySQL/PostgreSQL/Oracle.

      This one has a bigger scope than https://issues.apache.org/jira/browse/SPARK-28741

      Attachments

        Activity

          People

            Gengliang.Wang Gengliang Wang
            Gengliang.Wang Gengliang Wang
            Votes:
            0 Vote for this issue
            Watchers:
            5 Start watching this issue

            Dates

              Created:
              Updated:
              Resolved: