diff --git a/server/services/store/sqlstore/schema_table_migration.go b/server/services/store/sqlstore/schema_table_migration.go index 913a5320c..7a6f911dd 100644 --- a/server/services/store/sqlstore/schema_table_migration.go +++ b/server/services/store/sqlstore/schema_table_migration.go @@ -123,11 +123,8 @@ func (s *SQLStore) isSchemaMigrationNeeded() (bool, error) { "TABLE_NAME": s.tablePrefix + "schema_migrations", }) - switch s.dbType { - case model.MysqlDBType: + if s.dbType == model.MysqlDBType { query = query.Where(sq.Eq{"TABLE_SCHEMA": s.schemaName}) - case model.PostgresDBType: - query = query.Where(sq.Eq{"TABLE_SCHEMA": "current_schema()"}) } rows, err := query.Query()