2021-08-25 15:34:33 +02:00
|
|
|
package dialect
|
|
|
|
|
|
|
|
type Name int
|
|
|
|
|
|
|
|
func (n Name) String() string {
|
|
|
|
switch n {
|
|
|
|
case PG:
|
|
|
|
return "pg"
|
|
|
|
case SQLite:
|
|
|
|
return "sqlite"
|
2021-09-08 21:05:26 +02:00
|
|
|
case MySQL:
|
|
|
|
return "mysql"
|
2022-04-24 12:26:22 +02:00
|
|
|
case MSSQL:
|
|
|
|
return "mssql"
|
2021-08-25 15:34:33 +02:00
|
|
|
default:
|
|
|
|
return "invalid"
|
|
|
|
}
|
|
|
|
}
|
|
|
|
|
|
|
|
const (
|
|
|
|
Invalid Name = iota
|
|
|
|
PG
|
|
|
|
SQLite
|
2021-09-08 21:05:26 +02:00
|
|
|
MySQL
|
2022-04-24 12:26:22 +02:00
|
|
|
MSSQL
|
2021-08-25 15:34:33 +02:00
|
|
|
)
|