- Sort Score
- Result 10 results
- Languages All
Results 1 - 6 of 6 for StableName (0.05 sec)
-
schema/naming_test.go
joinTable2 := ns.JoinTableName("UserLanguage") if joinTable2 != "public.user_language" { t.Errorf("invalid join table generated, got %v", joinTable2) } tableName := ns.TableName("Company") if tableName != "public.company" { t.Errorf("invalid table name generated, got %v", tableName) } columdName := ns.ColumnName("", "NameCID") if columdName != "name_cid" { t.Errorf("invalid column name generated, got %v", columdName) } }
Registered: Sun Nov 03 09:35:10 UTC 2024 - Last Modified: Tue May 30 02:00:48 UTC 2023 - 7K bytes - Viewed (0) -
migrator/index.go
import "database/sql" // Index implements gorm.Index interface type Index struct { TableName string NameValue string ColumnList []string PrimaryKeyValue sql.NullBool UniqueValue sql.NullBool OptionValue string } // Table return the table name of the index. func (idx Index) Table() string { return idx.TableName } // Name return the name of the index. func (idx Index) Name() string {
Registered: Sun Nov 03 09:35:10 UTC 2024 - Last Modified: Tue Apr 11 02:32:46 UTC 2023 - 1023 bytes - Viewed (0) -
schema/naming.go
IdentifierMaxLength int } // TableName convert string to table name func (ns NamingStrategy) TableName(str string) string { if ns.SingularTable { return ns.TablePrefix + ns.toDBName(str) } return ns.TablePrefix + inflection.Plural(ns.toDBName(str)) } // SchemaName generate schema name from table name, don't guarantee it is the reverse value of TableName func (ns NamingStrategy) SchemaName(table string) string {
Registered: Sun Nov 03 09:35:10 UTC 2024 - Last Modified: Wed Jun 12 03:46:59 UTC 2024 - 5.3K bytes - Viewed (0) -
internal/event/target/postgresql_test.go
found = true break } } if !found { t.Fatal("postgres driver not registered") } } func TestPsqlTableNameValidation(t *testing.T) { validTables := []string{"táblë", "table", "TableName", "\"Table name\"", "\"✅✅\"", "table$one", "\"táblë\""} invalidTables := []string{"table name", "table \"name\"", "✅✅", "$table$"} for _, name := range validTables { if err := validatePsqlTableName(name); err != nil {
Registered: Sun Nov 03 19:28:11 UTC 2024 - Last Modified: Wed Apr 24 17:51:07 UTC 2024 - 1.7K bytes - Viewed (0) -
tests/serializer_test.go
CustomSerializerString string `gorm:"serializer:custom"` EncryptedString EncryptedString } func (*SerializerPostgresStruct) TableName() string { return "serializer_structs" } func adaptorSerializerModel(s *SerializerStruct) interface{} { if DB.Dialector.Name() == "postgres" { sps := SerializerPostgresStruct(*s) return &sps } return s }
Registered: Sun Nov 03 09:35:10 UTC 2024 - Last Modified: Fri Apr 21 14:09:38 UTC 2023 - 7.6K bytes - Viewed (0) -
schema/schema_helper_test.go
} if r.JoinTable.Table != relation.JoinTable.Table { t.Errorf("schema %v relation's join table tablename expects %v, but got %v", s, relation.JoinTable.Table, r.JoinTable.Table) } for i := range relation.JoinTable.Fields { checkSchemaField(t, r.JoinTable, &relation.JoinTable.Fields[i], nil) } }
Registered: Sun Nov 03 09:35:10 UTC 2024 - Last Modified: Fri Dec 15 08:31:23 UTC 2023 - 7.5K bytes - Viewed (0)