Merge 0f675167d0
into e8fbd41c16
This commit is contained in:
commit
daaaacf3e3
|
@ -196,7 +196,9 @@ func (statement *Statement) Or(query interface{}, args ...interface{}) *Statemen
|
||||||
// In generate "Where column IN (?) " statement
|
// In generate "Where column IN (?) " statement
|
||||||
func (statement *Statement) In(column string, args ...interface{}) *Statement {
|
func (statement *Statement) In(column string, args ...interface{}) *Statement {
|
||||||
if len(args) == 0 {
|
if len(args) == 0 {
|
||||||
return statement
|
// use a false condition, since there isn't an easy way to have
|
||||||
|
// an empty list in SQL
|
||||||
|
return statement.And("0=1")
|
||||||
}
|
}
|
||||||
|
|
||||||
in := builder.In(column, args...)
|
in := builder.In(column, args...)
|
||||||
|
|
Loading…
Reference in New Issue