prorm API Reference
    Preparing search index...

    Base class for all data types

    Hierarchy (View Summary)

    Index
    • Create a DOUBLE data type

      Parameters

      • OptionalprecisionOrOptions: number | { precision?: number; decimals?: number; unsigned?: boolean }

        Either a precision number or an options object

      Returns DOUBLE

      // Simple DOUBLE
      DataTypes.DOUBLE()
      // DOUBLE with precision (MySQL/MariaDB)
      DataTypes.DOUBLE(16)
      // DOUBLE with options (backward compatibility)
      DataTypes.DOUBLE({ precision: 16, decimals: 4, unsigned: true })
    key: "DOUBLE" = ...
    precision?: number

    Precision (total number of digits) - MySQL/MariaDB specific

    decimals?: number

    Number of decimal places

    unsigned?: boolean

    Whether the value is unsigned

    • Serialize a value for storage based on this DataType

      Parameters

      • value: unknown

        The value to serialize

      Returns unknown

      The serialized value