MCPcopy
hub / github.com/ent/ent / LenNEQ

Function LenNEQ

dialect/sql/sqljson/sqljson.go:287–292  ·  view source on GitHub ↗

LenNEQ return a predicate for checking that an array length of a JSON (returned by the path) is not equal to the given argument. sqljson.LenEQ("a", 1, sqljson.Path("b"))

(column string, size int, opts ...Option)

Source from the content-addressed store, hash-verified

285//
286// sqljson.LenEQ("a", 1, sqljson.Path("b"))
287func LenNEQ(column string, size int, opts ...Option) *sql.Predicate {
288 return sql.P(func(b *sql.Builder) {
289 lenPath(b, column, opts...)
290 b.WriteOp(sql.OpNEQ).Arg(size)
291 })
292}
293
294// LenGT return a predicate for checking that an array length
295// of a JSON (returned by the path) is greater than the given

Callers

nothing calls this directly

Calls 4

PStruct · 0.92
lenPathFunction · 0.85
ArgMethod · 0.80
WriteOpMethod · 0.80

Tested by

no test coverage detected

Used in the wild real call sites across dependent graphs

searching dependent graphs…