MCPcopy
hub / github.com/dropbox/godropbox / Neq

Function Neq

database/sqlbuilder/expression.go:455–461  ·  view source on GitHub ↗

Returns a representation of "a!=b"

(lhs, rhs Expression)

Source from the content-addressed store, hash-verified

453
454// Returns a representation of "a!=b"
455func Neq(lhs, rhs Expression) BoolExpression {
456 lit, ok := rhs.(*literalExpression)
457 if ok && sqltypes.Value(lit.value).IsNull() {
458 return newBoolExpression(lhs, rhs, []byte(" IS NOT "))
459 }
460 return newBoolExpression(lhs, rhs, []byte("!="))
461}
462
463// Returns a representation of "a!=b", where b is a literal
464func NeqL(lhs Expression, val interface{}) BoolExpression {

Callers 1

NeqLFunction · 0.85

Calls 3

ValueStruct · 0.92
newBoolExpressionFunction · 0.85
IsNullMethod · 0.80

Tested by

no test coverage detected