Uploaded image for project: 'Spark'
  1. Spark
  2. SPARK-27764 Feature Parity between PostgreSQL and Spark
  3. SPARK-28461

Pad Decimal numbers with trailing zeros to the scale of the column

    XMLWordPrintableJSON

Details

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

    Description

      PostgreSQL:

      postgres=# select cast(1 as decimal(38, 18));
             numeric
      ----------------------
       1.000000000000000000
      (1 row)
      

      Spark SQL:

      spark-sql> select cast(1 as decimal(38, 18));
      1
      spark-sql>
      

      Hive fix this issue by HIVE-12063.

      Attachments

        Issue Links

          Activity

            People

              yumwang Yuming Wang
              yumwang Yuming Wang
              Votes:
              0 Vote for this issue
              Watchers:
              4 Start watching this issue

              Dates

                Created:
                Updated:
                Resolved: