mirror of
https://github.com/silverstripe/silverstripe-mssql
synced 2024-10-22 08:05:53 +02:00
MINOR Code tidy up in MSSQLDatabase
This commit is contained in:
parent
530a780a90
commit
075f4e53b9
@ -987,7 +987,7 @@ class MSSQLDatabase extends SS_Database {
|
||||
* Returns the SQL command to get all the tables in this database
|
||||
*/
|
||||
function allTablesSQL(){
|
||||
return "SELECT \"name\" FROM \"{$this->database}\"..sysobjects WHERE \"xtype\" = 'U';";
|
||||
return "SELECT \"name\" FROM \"sys\".\"tables\";";
|
||||
}
|
||||
|
||||
/**
|
||||
@ -1134,11 +1134,11 @@ class MSSQLDatabase extends SS_Database {
|
||||
return $value;
|
||||
}
|
||||
|
||||
/*
|
||||
/**
|
||||
* This changes the index name depending on database requirements.
|
||||
* MSSQL requires commas to be replaced with underscores
|
||||
* MSSQL requires underscores to be replaced with commas.
|
||||
*/
|
||||
function modifyIndex($index){
|
||||
function modifyIndex($index) {
|
||||
return str_replace('_', ',', $index);
|
||||
}
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user