Search Options

Results per page
Sort
Preferred Languages
Advance

Results 1 - 3 of 3 for Preload (0.19 sec)

  1. callbacks/preload.go

    		identityMap, foreignValues = schema.GetIdentityFieldValuesMap(tx.Statement.Context, reflectValue, foreignFields)
    		if len(foreignValues) == 0 {
    			return nil
    		}
    	}
    
    	// nested preload
    	for p, pvs := range preloads {
    		tx = tx.Preload(p, pvs...)
    	}
    
    	reflectResults := rel.FieldSchema.MakeSlice().Elem()
    	column, values := schema.ToQueryValues(clause.CurrentTable, relForeignKeys, foreignValues)
    
    	if len(values) != 0 {
    Go
    - Registered: Sun May 05 09:35:13 GMT 2024
    - Last Modified: Thu Apr 25 12:21:03 GMT 2024
    - 11.6K bytes
    - Viewed (0)
  2. tests/preload_test.go

    	)
    
    	DB.Migrator().DropTable(&Preload{}, &Join{}, &Nested{}, &Value{})
    	DB.Migrator().AutoMigrate(&Preload{}, &Join{}, &Nested{}, &Value{})
    
    	value1 := Value{
    		Name: "value",
    		Nested: Nested{
    			Preloads: []*Preload{
    				{Value: "p1"}, {Value: "p2"},
    			},
    			Join: Join{Value: "j1"},
    		},
    	}
    	value2 := Value{
    		Name: "value2",
    		Nested: Nested{
    			Preloads: []*Preload{
    Go
    - Registered: Sun May 05 09:35:13 GMT 2024
    - Last Modified: Thu Apr 25 12:21:03 GMT 2024
    - 14.9K bytes
    - Viewed (0)
  3. errors.go

    	// ErrInvalidValueOfLength invalid values do not match length
    	ErrInvalidValueOfLength = errors.New("invalid association values, length doesn't match")
    	// ErrPreloadNotAllowed preload is not allowed when count is used
    	ErrPreloadNotAllowed = errors.New("preload is not allowed when count is used")
    	// ErrDuplicatedKey occurs when there is a unique key constraint violation
    	ErrDuplicatedKey = errors.New("duplicated key not allowed")
    Go
    - Registered: Sun May 05 09:35:13 GMT 2024
    - Last Modified: Fri Apr 26 02:53:17 GMT 2024
    - 2.5K bytes
    - Viewed (0)
Back to top