diff --git a/GORM-V2-Release-Note-Draft.md b/GORM-V2-Release-Note-Draft.md index 49b667e..2b95deb 100644 --- a/GORM-V2-Release-Note-Draft.md +++ b/GORM-V2-Release-Note-Draft.md @@ -47,7 +47,7 @@ func init() { // during initialization, you can use `gorm.Config` to change few configurations, e.g: NowFunc, which no longer allow modification through global variables db, err := gorm.Open(sqlite.Open("gorm.db"), &gorm.Config{NowFunc: func() time.Time { return time.Now().Local() }}) db, err := gorm.Open(mysql.Open("gorm:gorm@tcp(localhost:9910)/gorm?charset=utf8&parseTime=True"), &gorm.Config{}) - db, err := gorm.Open(postgres.Open("user=gorm password=gorm DB.name=gorm port=9920 TimeZone=Asia/Shanghai"), &gorm.Config{}) + db, err := gorm.Open(postgres.Open("user=gorm password=gorm dbname=gorm port=9920 TimeZone=Asia/Shanghai"), &gorm.Config{}) // most CRUD API kept compatibility db.AutoMigrate(&Product{})