SQLNullFloat64KeyOmitEmpty adds a string to be encoded or skips it if it is zero value. Must be used inside an object as it will encode a key
(key string, v *sql.NullFloat64)
| 273 | // SQLNullFloat64KeyOmitEmpty adds a string to be encoded or skips it if it is zero value. |
| 274 | // Must be used inside an object as it will encode a key |
| 275 | func (enc *Encoder) SQLNullFloat64KeyOmitEmpty(key string, v *sql.NullFloat64) { |
| 276 | if v != nil && v.Valid && v.Float64 != 0 { |
| 277 | enc.Float64KeyOmitEmpty(key, v.Float64) |
| 278 | } |
| 279 | } |
| 280 | |
| 281 | // SQLNullFloat64KeyNullEmpty adds a string to be encoded or skips it if it is zero value. |
| 282 | // Must be used inside an object as it will encode a key |