- Sort Score
- Result 10 results
- Languages All
Results 1 - 10 of 24 for conds (0.02 sec)
-
statement.go
if len(values) > 0 { conds = append(conds, clause.IN{Column: clause.PrimaryColumn, Values: values}) return []clause.Expression{clause.And(conds...)} } return nil } } conds = append(conds, clause.IN{Column: clause.PrimaryColumn, Values: args}) } } } if len(conds) > 0 { return []clause.Expression{clause.And(conds...)} } return nil }
Registered: Sun Nov 03 09:35:10 UTC 2024 - Last Modified: Mon Jun 24 09:42:59 UTC 2024 - 19.9K bytes - Viewed (0) -
association.go
conds = append(conds, clause.IN{Column: pcolumn, Values: pvalues}) } else { return ErrPrimaryKeyRequired } _, rvs := schema.GetIdentityFieldValuesMapFromValues(association.DB.Statement.Context, values, primaryFields) relColumn, relValues := schema.ToQueryValues(rel.Schema.Table, foreignKeys, rvs) conds = append(conds, clause.IN{Column: relColumn, Values: relValues})
Registered: Sun Nov 03 09:35:10 UTC 2024 - Last Modified: Wed Jun 12 10:49:45 UTC 2024 - 21.5K bytes - Viewed (0) -
chainable_api.go
func (db *DB) Clauses(conds ...clause.Expression) (tx *DB) { tx = db.getInstance() var whereConds []interface{} for _, cond := range conds { if c, ok := cond.(clause.Interface); ok { tx.Statement.AddClause(c) } else if optimizer, ok := cond.(StatementModifier); ok { optimizer.ModifyStatement(tx.Statement) } else { whereConds = append(whereConds, cond) } } if len(whereConds) > 0 {
Registered: Sun Nov 03 09:35:10 UTC 2024 - Last Modified: Mon Jun 24 09:42:59 UTC 2024 - 14.8K bytes - Viewed (0) -
finisher_api.go
// First finds the first record ordered by primary key, matching given conditions conds func (db *DB) First(dest interface{}, conds ...interface{}) (tx *DB) { tx = db.Limit(1).Order(clause.OrderByColumn{ Column: clause.Column{Table: clause.CurrentTable, Name: clause.PrimaryKey}, }) if len(conds) > 0 { if exprs := tx.Statement.BuildCondition(conds[0], conds[1:]...); len(exprs) > 0 { tx.Statement.AddClause(clause.Where{Exprs: exprs})
Registered: Sun Nov 03 09:35:10 UTC 2024 - Last Modified: Sat Sep 14 12:58:29 UTC 2024 - 22.8K bytes - Viewed (0) -
callbacks/query.go
var conds []clause.Expression for _, primaryField := range db.Statement.Schema.PrimaryFields { if v, isZero := primaryField.ValueOf(db.Statement.Context, db.Statement.ReflectValue); !isZero { conds = append(conds, clause.Eq{Column: clause.Column{Table: db.Statement.Table, Name: primaryField.DBName}, Value: v}) } } if len(conds) > 0 {
Registered: Sun Nov 03 09:35:10 UTC 2024 - Last Modified: Thu Aug 22 11:03:42 UTC 2024 - 10.1K bytes - Viewed (1) -
schema/relationship.go
relForeignKeys = append(relForeignKeys, ref.ForeignKey.DBName) } else if ref.PrimaryValue != "" { conds = append(conds, clause.Eq{ Column: clause.Column{Table: rel.JoinTable.Table, Name: ref.ForeignKey.DBName}, Value: ref.PrimaryValue, }) } else { conds = append(conds, clause.Eq{ Column: clause.Column{Table: rel.JoinTable.Table, Name: ref.ForeignKey.DBName},
Registered: Sun Nov 03 09:35:10 UTC 2024 - Last Modified: Wed Jun 12 03:46:59 UTC 2024 - 22.7K bytes - Viewed (0) -
callbacks/preload.go
column, values := schema.ToQueryValues(clause.CurrentTable, relForeignKeys, foreignValues) if len(values) != 0 { for _, cond := range conds { if fc, ok := cond.(func(*gorm.DB) *gorm.DB); ok { tx = fc(tx) } else { inlineConds = append(inlineConds, cond) } }
Registered: Sun Nov 03 09:35:10 UTC 2024 - Last Modified: Wed Jun 12 10:52:33 UTC 2024 - 11.6K bytes - Viewed (0) -
tests/joins_test.go
return users[i].ID > users[j].ID }) for idx, user := range users { CheckUser(t, user, users2[idx]) } } func TestJoinConds(t *testing.T) { user := *GetUser("joins-conds", Config{Account: true, Pets: 3}) DB.Save(&user) var users1 []User DB.Joins("inner join pets on pets.user_id = users.id").Where("users.name = ?", user.Name).Find(&users1) if len(users1) != 3 {
Registered: Sun Nov 03 09:35:10 UTC 2024 - Last Modified: Mon Jun 17 03:58:13 UTC 2024 - 15K bytes - Viewed (0) -
cmd/postpolicyform.go
} case []interface{}: // Handle array types. if len(condt) != 3 { // Return error if we have insufficient elements. return parsedPolicy, fmt.Errorf("Malformed conditional fields %s of type %s found in POST policy form", condt, reflect.TypeOf(condt).String()) } switch toLowerString(condt[0]) { case policyCondEqual, policyCondStartsWith: for _, v := range condt { // Pre-check all values for type. if !isString(v) {
Registered: Sun Nov 03 19:28:11 UTC 2024 - Last Modified: Mon Sep 23 19:35:41 UTC 2024 - 12.4K bytes - Viewed (0) -
src/cmd/asm/internal/arch/arm.go
// codes, such as ".P.W". An initial period is ignored. func ParseARMCondition(cond string) (uint8, bool) { return parseARMCondition(cond, armLS, armSCOND) } func parseARMCondition(cond string, ls, scond map[string]uint8) (uint8, bool) { cond = strings.TrimPrefix(cond, ".") if cond == "" { return arm.C_SCOND_NONE, true } names := strings.Split(cond, ".") bits := uint8(0) for _, name := range names {
Registered: Tue Nov 05 11:13:11 UTC 2024 - Last Modified: Wed Oct 23 15:18:14 UTC 2024 - 6.1K bytes - Viewed (0)