Search Options

Results per page
Sort
Preferred Languages
Advance

Results 1 - 3 of 3 for checkMissingWhereConditions (0.28 sec)

  1. callbacks/delete.go

    					}
    				}
    			}
    
    			db.Statement.AddClauseIfNotExists(clause.From{})
    
    			db.Statement.Build(db.Statement.BuildClauses...)
    		}
    
    		checkMissingWhereConditions(db)
    
    		if !db.DryRun && db.Error == nil {
    			ok, mode := hasReturning(db, supportReturning)
    			if !ok {
    Go
    - Registered: Sun May 05 09:35:13 GMT 2024
    - Last Modified: Fri Feb 25 02:48:23 GMT 2022
    - 5.6K bytes
    - Viewed (0)
  2. callbacks/helper.go

    				return true, 0
    			}
    			return true, gorm.ScanUpdate
    		}
    	}
    	return false, 0
    }
    
    func checkMissingWhereConditions(db *gorm.DB) {
    	if !db.AllowGlobalUpdate && db.Error == nil {
    		where, withCondition := db.Statement.Clauses["WHERE"]
    		if withCondition {
    Go
    - Registered: Sun May 05 09:35:13 GMT 2024
    - Last Modified: Thu Apr 14 12:32:57 GMT 2022
    - 3.7K bytes
    - Viewed (0)
  3. callbacks/update.go

    					defer delete(db.Statement.Clauses, "SET")
    					db.Statement.AddClause(set)
    				} else {
    					return
    				}
    			}
    
    			db.Statement.Build(db.Statement.BuildClauses...)
    		}
    
    		checkMissingWhereConditions(db)
    
    		if !db.DryRun && db.Error == nil {
    			if ok, mode := hasReturning(db, supportReturning); ok {
    Go
    - Registered: Sun May 05 09:35:13 GMT 2024
    - Last Modified: Mon Mar 18 05:44:55 GMT 2024
    - 9.4K bytes
    - Viewed (1)
Back to top