Search Options

Results per page
Sort
Preferred Languages
Advance

Results 1 - 4 of 4 for AndConditions (0.14 sec)

  1. clause/where.go

    		return nil
    	}
    
    	if len(exprs) == 1 {
    		if _, ok := exprs[0].(OrConditions); !ok {
    			return exprs[0]
    		}
    	}
    
    	return AndConditions{Exprs: exprs}
    }
    
    type AndConditions struct {
    	Exprs []Expression
    }
    
    func (and AndConditions) Build(builder Builder) {
    	if len(and.Exprs) > 1 {
    		builder.WriteByte('(')
    		buildExprs(and.Exprs, builder, AndWithSpace)
    		builder.WriteByte(')')
    Registered: Sun Nov 03 09:35:10 UTC 2024
    - Last Modified: Thu Apr 25 12:22:53 UTC 2024
    - 5.1K bytes
    - Viewed (0)
  2. clause/where_test.go

    			[]interface{}{100, 60},
    		},
    		{
    			[]clause.Interface{clause.Select{}, clause.From{}, clause.Where{
    				Exprs: []clause.Expression{
    					clause.Not(clause.AndConditions{
    						Exprs: []clause.Expression{
    							clause.Eq{Column: clause.PrimaryColumn, Value: "1"},
    							clause.Gt{Column: "age", Value: 18},
    						}}, clause.OrConditions{
    						Exprs: []clause.Expression{
    Registered: Sun Nov 03 09:35:10 UTC 2024
    - Last Modified: Thu Apr 25 12:22:53 UTC 2024
    - 6.2K bytes
    - Viewed (0)
  3. finisher_api.go

    							db.AddError(field.Set(db.Statement.Context, db.Statement.ReflectValue, eq.Value))
    						}
    					}
    				} else if andCond, ok := expr.(clause.AndConditions); ok {
    					db.assignInterfacesToValue(andCond.Exprs)
    				}
    			}
    		case clause.Expression, map[string]string, map[interface{}]interface{}, map[string]interface{}:
    Registered: Sun Nov 03 09:35:10 UTC 2024
    - Last Modified: Sat Sep 14 12:58:29 UTC 2024
    - 22.8K bytes
    - Viewed (0)
  4. statement.go

    				if where, ok := cs.Expression.(clause.Where); ok {
    					if len(where.Exprs) == 1 {
    						if orConds, ok := where.Exprs[0].(clause.OrConditions); ok {
    							where.Exprs[0] = clause.AndConditions(orConds)
    						}
    					}
    					conds = append(conds, clause.And(where.Exprs...))
    				} else if cs.Expression != nil {
    					conds = append(conds, cs.Expression)
    				}
    			}
    Registered: Sun Nov 03 09:35:10 UTC 2024
    - Last Modified: Mon Jun 24 09:42:59 UTC 2024
    - 19.9K bytes
    - Viewed (0)
Back to top