Commit 91a6532d authored by Juozas Kaziukenas's avatar Juozas Kaziukenas

Added databases list support

parent 0c9fe1d8
......@@ -92,6 +92,10 @@ class MsSqlPlatform extends AbstractPlatform
*/
public function getDropDatabaseSQL($name)
{
return 'ALTER DATABASE [' . $name . ']
SET SINGLE_USER --or RESTRICTED_USER
WITH ROLLBACK IMMEDIATE;
DROP DATABASE ' . $name . ';';
return 'DROP DATABASE ' . $name;
}
......@@ -293,6 +297,11 @@ class MsSqlPlatform extends AbstractPlatform
$args = func_get_args();
return '(' . implode(' + ', $args) . ')';
}
public function getListDatabasesSQL()
{
return 'SELECT * FROM SYS.DATABASES';
}
/**
* @override
......
......@@ -230,4 +230,12 @@ class MsSqlSchemaManager extends AbstractSchemaManager
{
return $table['name'];
}
/**
* @override
*/
protected function _getPortableDatabaseDefinition($database)
{
return $database['name'];
}
}
\ No newline at end of file
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment