Search Options

Results per page
Sort
Preferred Languages
Advance

Results 1 - 2 of 2 for SplitNestedRelationName (0.07 sec)

  1. utils/utils.go

    func NestedRelationName(prefix, name string) string {
    	return prefix + nestedRelationSplit + name
    }
    
    // SplitNestedRelationName Split nested relationships to `[]string{"Manager","Company"}`
    func SplitNestedRelationName(name string) []string {
    	return strings.Split(name, nestedRelationSplit)
    }
    
    // JoinNestedRelationNames nested relationships like `Manager__Company`
    Registered: Sun Sep 07 09:35:13 UTC 2025
    - Last Modified: Thu Aug 22 11:03:42 UTC 2024
    - 4.1K bytes
    - Viewed (0)
  2. scan.go

    										fields[idx] = selectField
    										break
    									}
    									count--
    								}
    							}
    						} else {
    							matchedFieldCount[column] = 1
    						}
    					} else if names := utils.SplitNestedRelationName(column); len(names) > 1 { // has nested relation
    						aliasName := utils.JoinNestedRelationNames(names[0 : len(names)-1])
    						for _, join := range db.Statement.Joins {
    							if join.Alias == aliasName {
    Registered: Sun Sep 07 09:35:13 UTC 2025
    - Last Modified: Sun May 25 07:40:40 UTC 2025
    - 10.4K bytes
    - Viewed (0)
Back to top