MCPcopy
hub / github.com/shopspring/decimal / Value

Method Value

decimal.go:2068–2073  ·  view source on GitHub ↗

Value implements the driver.Valuer interface for database serialization.

()

Source from the content-addressed store, hash-verified

2066
2067// Value implements the driver.Valuer interface for database serialization.
2068func (d NullDecimal) Value() (driver.Value, error) {
2069 if !d.Valid {
2070 return nil, nil
2071 }
2072 return d.Decimal.Value()
2073}
2074
2075// UnmarshalJSON implements the json.Unmarshaler interface.
2076func (d *NullDecimal) UnmarshalJSON(decimalBytes []byte) error {

Callers 1

TestNullDecimal_ValueFunction · 0.95

Calls 1

ValueMethod · 0.45

Tested by 1

TestNullDecimal_ValueFunction · 0.76