Search Options

Results per page
Sort
Preferred Languages
Advance

Results 1 - 1 of 1 for column_structs (0.15 sec)

  1. tests/migrate_test.go

    	type ColumnStruct2 struct {
    		gorm.Model
    		Name  string `gorm:"size:100"`
    		Code  string `gorm:"unique;comment:my code2;default:hello"`
    		Code2 string `gorm:"unique"`
    		// Code3 string
    	}
    
    	if err := DB.Table("column_structs").Migrator().AlterColumn(&ColumnStruct{}, "Name"); err != nil {
    		t.Fatalf("no error should happened when alter column, but got %v", err)
    	}
    
    Registered: Sun Sep 07 09:35:13 UTC 2025
    - Last Modified: Wed Aug 20 04:51:17 UTC 2025
    - 65.2K bytes
    - Viewed (0)
Back to top