Share via


DecimalType(Int32, Int32) Constructor

Definition

Initializes the DecimalType instance.

public DecimalType (int precision = 10, int scale = 0);
new Microsoft.Spark.Sql.Types.DecimalType : int * int -> Microsoft.Spark.Sql.Types.DecimalType
Public Sub New (Optional precision As Integer = 10, Optional scale As Integer = 0)

Parameters

precision
Int32

Number of digits in a number

scale
Int32

Number of digits to the right of the decimal point in a number

Remarks

Default values of precision and scale are from Scala: sql/catalyst/src/main/scala/org/apache/spark/sql/types/DecimalType.scala.

Applies to