Uploaded image for project: 'Spark'
  1. Spark
  2. SPARK-41047

Remove legacy example of round function with negative scale

    XMLWordPrintableJSON

Details

    • Bug
    • Status: Resolved
    • Trivial
    • Resolution: Fixed
    • 3.2.2
    • 3.4.0
    • Documentation, SQL
    • None

    Description

      Run this sql in spark-sql: select round(1.233, -1);
      Error: org.apache.spark.sql.AnalysisException: Negative scale is not allowed: -1. You can use spark.sql.legacy.allowNegativeScaleOfDecimal=true to enable legacy mode to allow it.;

      But the document of round function implies that negative scale argument is allowed.

      Attachments

        Activity

          People

            panbingkun Pan Bingkun
            taiyang-li liyang
            Votes:
            0 Vote for this issue
            Watchers:
            3 Start watching this issue

            Dates

              Created:
              Updated:
              Resolved: