- Sort Score
- Result 10 results
- Languages All
Results 1 - 10 of 12 for Renoth (0.17 sec)
-
schema/constraint.go
"strings" "gorm.io/gorm/clause" ) // reg match english letters and midline var regEnLetterAndMidline = regexp.MustCompile(`^[\w-]+$`) type CheckConstraint struct { Name string Constraint string // length(phone) >= 10 *Field } func (chk *CheckConstraint) GetName() string { return chk.Name } func (chk *CheckConstraint) Build() (sql string, vars []interface{}) {
Go - Registered: Sun May 05 09:35:13 GMT 2024 - Last Modified: Mon Mar 18 07:33:54 GMT 2024 - 1.9K bytes - Viewed (0) -
migrator/migrator.go
Go - Registered: Sun May 05 09:35:13 GMT 2024 - Last Modified: Fri Apr 26 07:15:49 GMT 2024 - 29K bytes - Viewed (0) -
tests/migrate_test.go
t.Fatalf("column name type should be correct, name: %v, length: %v, expects: %v, column: %#v", columnType.Name(), columnType.DatabaseTypeName(), dataType, columnType) } if length, ok := columnType.Length(); !ok || length != 100 { t.Fatalf("column name length should be correct, name: %v, length: %v, expects: %v, column: %#v", columnType.Name(), length, 100, columnType) } case "age":
Go - Registered: Sun May 05 09:35:13 GMT 2024 - Last Modified: Mon Mar 18 11:24:16 GMT 2024 - 56.2K bytes - Viewed (0) -
errors.go
// ErrInvalidValue invalid value ErrInvalidValue = errors.New("invalid value, should be pointer to struct or slice") // 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")
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) -
migrator.go
Name() string DatabaseTypeName() string // varchar ColumnType() (columnType string, ok bool) // varchar(64) PrimaryKey() (isPrimaryKey bool, ok bool) AutoIncrement() (isAutoIncrement bool, ok bool) Length() (length int64, ok bool) DecimalSize() (precision int64, scale int64, ok bool) Nullable() (nullable bool, ok bool) Unique() (unique bool, ok bool) ScanType() reflect.Type Comment() (value string, ok bool)
Go - Registered: Sun May 05 09:35:13 GMT 2024 - Last Modified: Mon Oct 30 09:15:49 GMT 2023 - 3.1K bytes - Viewed (0) -
finisher_api.go
reflectValue := reflect.Indirect(reflect.ValueOf(value)) switch reflectValue.Kind() { case reflect.Slice, reflect.Array: var rowsAffected int64 tx = db.getInstance() // the reflection length judgment of the optimized value reflectLen := reflectValue.Len() callFc := func(tx *DB) error { for i := 0; i < reflectLen; i += batchSize { ends := i + batchSize if ends > reflectLen {
Go - Registered: Sun May 05 09:35:13 GMT 2024 - Last Modified: Fri Jan 12 08:42:21 GMT 2024 - 22.7K bytes - Viewed (0) -
schema/index.go
tag = strings.Join(v[1:], ":") idx = strings.Index(tag, ",") tagSetting = strings.Join(strings.Split(tag, ",")[1:], ",") settings = ParseTagSetting(tagSetting, ",") length, _ = strconv.Atoi(settings["LENGTH"]) ) if idx == -1 { idx = len(tag) } if idx != -1 { name = tag[0:idx] } if name == "" { subName := field.Name
Go - Registered: Sun May 05 09:35:13 GMT 2024 - Last Modified: Sun Feb 04 07:49:19 GMT 2024 - 3.7K bytes - Viewed (0) -
schema/index_test.go
if len(ei.Fields) != len(ai.Fields) { t.Errorf("expected index %q field length is %d but actual %d", k, len(ei.Fields), len(ai.Fields)) return } for i, ef := range ei.Fields { af := ai.Fields[i] tests.AssertObjEqual(t, af, ef, "Name", "Unique", "UniqueIndex", "Expression", "Sort", "Collate", "Length") } }) delete(actual, k) } for k := range actual {
Go - Registered: Sun May 05 09:35:13 GMT 2024 - Last Modified: Sun Feb 04 07:49:19 GMT 2024 - 8K bytes - Viewed (0) -
statement.go
conds = append(conds, clause.Eq{Column: key, Value: v[key]}) } else if _, ok := v[key].(Valuer); ok { conds = append(conds, clause.Eq{Column: key, Value: v[key]}) } else { // optimize reflect value length valueLen := reflectValue.Len() values := make([]interface{}, valueLen) for i := 0; i < valueLen; i++ { values[i] = reflectValue.Index(i).Interface() }
Go - Registered: Sun May 05 09:35:13 GMT 2024 - Last Modified: Fri Jan 12 08:42:21 GMT 2024 - 19.8K bytes - Viewed (0) -
tests/associations_belongs_to_test.go
if err := DB.Model(&users).Association("Manager").Append( GetUser("manager-slice-belongs-to-test-1", Config{}), ).Error; err == nil { t.Errorf("unmatched length when update user's manager") } // Replace -> same as append // Delete if err := DB.Model(&users).Association("Company").Delete(&users[0].Company); err != nil {
Go - Registered: Sun May 05 09:35:13 GMT 2024 - Last Modified: Mon Oct 30 09:15:49 GMT 2023 - 9.3K bytes - Viewed (0)