null icon indicating copy to clipboard operation
null copied to clipboard

reasonable handling of nullable values

Results 15 null issues
Sort by recently updated
recently updated
newest added

Any ideas or opinions on how to handle generics in this library? I played around with creating a generic `Null[T]` type, but I wonder if it's even useful at that...

Less of an issue, and more of an FYI. I have been keeping tabs on the (un)marshaling/(de)encoding issue with omitempty, and it looks like they have a adjacent proposal that...

In JSON there are effectively two types of null. 1) When the key is provided, and the value is explicitly stated as null. 2) When the key is not provided,...

Each struct of this library uses sql package (persistence or infrastructure layer), while it can be used for JSON marshaling (presentation layer). It seems to be against some software architecture...

This method allows you to determine whether the field was filled with marchal, which is useful for different merge models. For example: ` type MyModel struct { Name null.String Family...

Adds Int from sql.NullString (super helpful when dealing with id's on databases where the id might not be in a struct used to receive/pass to client). It's helpful for my...

// NewInt creates a new Int from a string func NewIntFromString(i string, valid bool) Int { if valid { inter, err := strconv.Atoi(i) if err != nil { return Int{...

Hi @guregu, I added a new method which checks if a string is zero or consists only of spaces. This is a helpful check especially for mandatory fields. Would it...

1. defind web api dto struct ```go type Dto struct { Start null.Time } ``` 2. send this json to web api ```json { "Start": null } ``` 4. service:...

I use beego with "nuu.v4", create struct type SysUserBean struct { UserId int64 `orm:"auto" json:"userId"` Username null.String `json:"username"` } when run "bee run", then tips, "field: models.SysUserBean.Username, unsupport field type...