MCPcopy Index your code
hub / github.com/ent/ent / FieldIsNull

Function FieldIsNull

dialect/sql/sql.go:19–23  ·  view source on GitHub ↗

The following helpers exist to simplify the way raw predicates are defined and used in both ent/schema and generated code. For full predicates API, check out the sql.P in builder.go. FieldIsNull returns a raw predicate to check if the given field is NULL.

(name string)

Source from the content-addressed store, hash-verified

17
18// FieldIsNull returns a raw predicate to check if the given field is NULL.
19func FieldIsNull(name string) func(*Selector) {
20 return func(s *Selector) {
21 s.Where(IsNull(s.C(name)))
22 }
23}
24
25// FieldNotNull returns a raw predicate to check if the given field is not NULL.
26func FieldNotNull(name string) func(*Selector) {

Callers 15

SourceIsNilFunction · 0.92
SourceURIIsNilFunction · 0.92
TextIsNilFunction · 0.92
DescriptionIsNilFunction · 0.92
BufferIsNilFunction · 0.92
NewNameIsNilFunction · 0.92
BlobIsNilFunction · 0.92
StateIsNilFunction · 0.92
StatusIsNilFunction · 0.92
WorkplaceIsNilFunction · 0.92
RolesIsNilFunction · 0.92
DefaultExprIsNilFunction · 0.92

Calls 3

IsNullFunction · 0.85
WhereMethod · 0.65
CMethod · 0.65

Tested by 1

TestFieldIsNullFunction · 0.68

Used in the wild real call sites across dependent graphs

searching dependent graphs…