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

DecimalType should not be singleton

    XMLWordPrintableJSON

Details

    • Bug
    • Status: Resolved
    • Blocker
    • Resolution: Fixed
    • 1.4.0
    • 1.4.0
    • PySpark, SQL
    • None

    Description

      The DecimalType can not be constructed with parameters. When it's constructed without parameters, we always get same objects, which is wrong.

      >>> from pyspark.sql.types import *
      >>> DecimalType(1, 2)
      Traceback (most recent call last):
        File "<stdin>", line 1, in <module>
      TypeError: __call__() takes exactly 1 argument (3 given)
      >>> DecimalType()
      DecimalType()
      

      Attachments

        Activity

          People

            davies Davies Liu
            davies Davies Liu
            Votes:
            0 Vote for this issue
            Watchers:
            3 Start watching this issue

            Dates

              Created:
              Updated:
              Resolved: