- Sort Score
- Result 10 results
- Languages All
Results 91 - 100 of 137 for migration (0.63 sec)
-
tests/postgres_test.go
if DB.Dialector.Name() != "postgres" { t.Skip() } type Thing struct { gorm.Model SomeID string OtherID string Data string } DB.Migrator().DropTable(&Thing{}) DB.Migrator().CreateTable(&Thing{}) if err := DB.Exec("ALTER TABLE things ADD CONSTRAINT some_id_other_id_unique UNIQUE (some_id, other_id)").Error; err != nil { t.Error(err) } thing := Thing{
Registered: Sun Dec 28 09:35:17 UTC 2025 - Last Modified: Sat Oct 08 09:16:32 UTC 2022 - 6.4K bytes - Viewed (0) -
internal/logger/legacy.go
) // Legacy envs const ( legacyEnvAuditLoggerHTTPEndpoint = "MINIO_AUDIT_LOGGER_HTTP_ENDPOINT" legacyEnvLoggerHTTPEndpoint = "MINIO_LOGGER_HTTP_ENDPOINT" ) // SetLoggerHTTPAudit - helper for migrating older config to newer KV format. func SetLoggerHTTPAudit(scfg config.Config, k string, args http.Config) { if !args.Enabled { // Do not enable audit targets, if not enabled return }
Registered: Sun Dec 28 19:28:13 UTC 2025 - Last Modified: Thu Aug 03 09:47:07 UTC 2023 - 2K bytes - Viewed (0) -
utils/tests/dummy_dialecter.go
LastInsertIDReversed: true, }) return nil } func (DummyDialector) DefaultValueOf(field *schema.Field) clause.Expression { return clause.Expr{SQL: "DEFAULT"} } func (DummyDialector) Migrator(*gorm.DB) gorm.Migrator { return nil } func (DummyDialector) BindVarTo(writer clause.Writer, stmt *gorm.Statement, v interface{}) { writer.WriteByte('?') }
Registered: Sun Dec 28 09:35:17 UTC 2025 - Last Modified: Mon Mar 06 06:03:31 UTC 2023 - 2.2K bytes - Viewed (0) -
tests/associations_test.go
type Profile struct { gorm.Model Number string MemberID uint `gorm:"not null"` } type Member struct { gorm.Model Profiles []Profile } DB.Migrator().DropTable(&Member{}, &Profile{}) if err := DB.AutoMigrate(&Member{}, &Profile{}); err != nil { t.Fatalf("Failed to migrate, got error: %v", err) } member := &Member{ Profiles: []Profile{{Registered: Sun Dec 28 09:35:17 UTC 2025 - Last Modified: Fri Sep 12 04:33:27 UTC 2025 - 13.3K bytes - Viewed (0) -
tests/preload_test.go
Preloads []*Preload Join Join ValueID uint } Value struct { ID uint Name string Nested Nested } ) 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"},
Registered: Sun Dec 28 09:35:17 UTC 2025 - Last Modified: Wed Jun 12 10:00:47 UTC 2024 - 15.9K bytes - Viewed (0) -
tests/error_translator_test.go
} dialectors := map[string]bool{"sqlite": true, "postgres": true, "gaussdb": true, "mysql": true, "sqlserver": true} if supported, found := dialectors[db.Dialector.Name()]; !(found && supported) { return } DB.Migrator().DropTable(&City{}) if err = db.AutoMigrate(&City{}); err != nil { t.Fatalf("failed to migrate cities table, got error: %v", err) } err = db.Create(&City{Name: "Kabul"}).Error if err != nil {
Registered: Sun Dec 28 09:35:17 UTC 2025 - Last Modified: Mon Jul 21 02:46:58 UTC 2025 - 3.1K bytes - Viewed (0) -
tests/update_has_one_test.go
Number2 string } type CustomizeUser struct { gorm.Model Name string Account CustomizeAccount `gorm:"foreignkey:UserID"` } DB.Migrator().DropTable(&CustomizeUser{}) DB.Migrator().DropTable(&CustomizeAccount{}) if err := DB.AutoMigrate(&CustomizeUser{}); err != nil { t.Fatalf("failed to migrate, got error: %v", err) }Registered: Sun Dec 28 09:35:17 UTC 2025 - Last Modified: Thu Jul 14 06:55:54 UTC 2022 - 3.6K bytes - Viewed (0) -
tests/hooks_test.go
} func TestRunCallbacks(t *testing.T) { DB.Migrator().DropTable(&Product{}) DB.AutoMigrate(&Product{}) p := Product{Code: "unique_code", Price: 100} DB.Save(&p) if !reflect.DeepEqual(p.GetCallTimes(), []int64{1, 1, 0, 1, 1, 0, 0, 0, 0}) {
Registered: Sun Dec 28 09:35:17 UTC 2025 - Last Modified: Mon Jun 17 03:59:06 UTC 2024 - 16.7K bytes - Viewed (0) -
okhttp/src/androidMain/assets/PublicSuffixDatabase.list
*.kitakyushu.jp *.kobe.jp *.kunden.ortsinfo.at *.landing.myjino.ru *.lcl.dev *.lclstage.dev *.linodeobjects.com *.magentosite.cloud *.me-central-1.airflow.amazonaws.com *.me-south-1.airflow.amazonaws.com *.migration.run *.mm *.moonscale.io *.my.canva.site *.my.canvasite.cn *.nagoya.jp *.nodebalancer.linode.com *.nom.br *.northflank.app *.np *.oci.customer-oci.com *.ocp.customer-oci.com *.ocs.customer-oci.com
Registered: Fri Dec 26 11:42:13 UTC 2025 - Last Modified: Tue Dec 31 14:50:53 UTC 2024 - 129.6K bytes - Viewed (2) -
migrator/table_type.go
package migrator import ( "database/sql" ) // TableType table type implements TableType interface type TableType struct { SchemaValue string NameValue string TypeValue string CommentValue sql.NullString } // Schema returns the schema of the table. func (ct TableType) Schema() string { return ct.SchemaValue } // Name returns the name of the table. func (ct TableType) Name() string {Registered: Sun Dec 28 09:35:17 UTC 2025 - Last Modified: Fri May 05 07:58:27 UTC 2023 - 688 bytes - Viewed (0)