SQLNullInt64KeyOmitEmpty 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.NullInt64)
| 175 | // SQLNullInt64KeyOmitEmpty adds a string to be encoded or skips it if it is zero value. |
| 176 | // Must be used inside an object as it will encode a key |
| 177 | func (enc *Encoder) SQLNullInt64KeyOmitEmpty(key string, v *sql.NullInt64) { |
| 178 | if v != nil && v.Valid && v.Int64 != 0 { |
| 179 | enc.Int64KeyOmitEmpty(key, v.Int64) |
| 180 | } |
| 181 | } |
| 182 | |
| 183 | // SQLNullInt64KeyNullEmpty adds a string to be encoded or skips it if it is zero value. |
| 184 | // Must be used inside an object as it will encode a key |