renamed sqlserver to mssql.

pull/169/head
Aleksei Maslov 2019-05-15 13:25:09 +08:00
parent e11a96e0db
commit 6896ffb1dd
5 changed files with 7 additions and 7 deletions

View File

@ -44,7 +44,7 @@ Drivers:
postgres
mysql
sqlite3
sqlserver
mssql
redshift
Examples:
@ -58,7 +58,7 @@ Examples:
goose mysql "user:password@/dbname?parseTime=true" status
goose redshift "postgres://user:password@qwerty.us-east-1.redshift.amazonaws.com:5439/db" status
goose tidb "user:password@/dbname?parseTime=true" status
goose sqlserver "sqlserver://user:password@dbname:1433?database=master" status
goose mssql "sqlserver://user:password@dbname:1433?database=master" status
Options:

View File

@ -1,4 +1,4 @@
// +build !no_sqlserver
// +build !no_mssql
package main

View File

@ -83,7 +83,7 @@ Drivers:
postgres
mysql
sqlite3
sqlserver
mssql
redshift
Examples:
@ -97,7 +97,7 @@ Examples:
goose mysql "user:password@/dbname?parseTime=true" status
goose redshift "postgres://user:password@qwerty.us-east-1.redshift.amazonaws.com:5439/db" status
goose tidb "user:password@/dbname?parseTime=true" status
goose sqlserver "sqlserver://user:password@dbname:1433?database=master" status
goose mssql "sqlserver://user:password@dbname:1433?database=master" status
Options:
`

2
db.go
View File

@ -20,7 +20,7 @@ func OpenDBWithDriver(driver string, dbstring string) (*sql.DB, error) {
}
switch driver {
case "postgres", "sqlite3", "mysql", "sqlserver":
case "postgres", "sqlite3", "mysql", "mssql":
return sql.Open(driver, dbstring)
default:
return nil, fmt.Errorf("unsupported driver %s", driver)

View File

@ -31,7 +31,7 @@ func SetDialect(d string) error {
dialect = &MySQLDialect{}
case "sqlite3":
dialect = &Sqlite3Dialect{}
case "sqlserver":
case "mssql":
dialect = &SqlServerDialect{}
case "redshift":
dialect = &RedshiftDialect{}