includes/db/DatabaseMssql.php 1 location
|
@@ 1344-1353 (lines=10) @@
|
| 1341 |
|
* @return bool|ResultWrapper |
| 1342 |
|
* @since 1.18 |
| 1343 |
|
*/ |
| 1344 |
|
public function dropTable( $tableName, $fName = __METHOD__ ) { |
| 1345 |
|
if ( !$this->tableExists( $tableName, $fName ) ) { |
| 1346 |
|
return false; |
| 1347 |
|
} |
| 1348 |
|
|
| 1349 |
|
// parent function incorrectly appends CASCADE, which we don't want |
| 1350 |
|
$sql = "DROP TABLE " . $this->tableName( $tableName ); |
| 1351 |
|
|
| 1352 |
|
return $this->query( $sql, $fName ); |
| 1353 |
|
} |
| 1354 |
|
|
| 1355 |
|
/** |
| 1356 |
|
* Called in the installer and updater. |
includes/libs/rdbms/database/Database.php 1 location
|
@@ 3338-3345 (lines=8) @@
|
| 3335 |
|
* @return bool|ResultWrapper |
| 3336 |
|
* @since 1.18 |
| 3337 |
|
*/ |
| 3338 |
|
public function dropTable( $tableName, $fName = __METHOD__ ) { |
| 3339 |
|
if ( !$this->tableExists( $tableName, $fName ) ) { |
| 3340 |
|
return false; |
| 3341 |
|
} |
| 3342 |
|
$sql = "DROP TABLE " . $this->tableName( $tableName ) . " CASCADE"; |
| 3343 |
|
|
| 3344 |
|
return $this->query( $sql, $fName ); |
| 3345 |
|
} |
| 3346 |
|
|
| 3347 |
|
public function getInfinity() { |
| 3348 |
|
return 'infinity'; |
includes/libs/rdbms/database/DatabaseSqlite.php 1 location
|
@@ 1028-1035 (lines=8) @@
|
| 1025 |
|
* @return bool|ResultWrapper |
| 1026 |
|
* @throws DBReadOnlyError |
| 1027 |
|
*/ |
| 1028 |
|
public function dropTable( $tableName, $fName = __METHOD__ ) { |
| 1029 |
|
if ( !$this->tableExists( $tableName, $fName ) ) { |
| 1030 |
|
return false; |
| 1031 |
|
} |
| 1032 |
|
$sql = "DROP TABLE " . $this->tableName( $tableName ); |
| 1033 |
|
|
| 1034 |
|
return $this->query( $sql, $fName ); |
| 1035 |
|
} |
| 1036 |
|
|
| 1037 |
|
protected function requiresDatabaseUser() { |
| 1038 |
|
return false; // just a file |
includes/libs/rdbms/database/DatabaseMysqlBase.php 1 location
|
@@ 1256-1262 (lines=7) @@
|
| 1253 |
|
* @param string $fName |
| 1254 |
|
* @return bool|ResultWrapper |
| 1255 |
|
*/ |
| 1256 |
|
public function dropTable( $tableName, $fName = __METHOD__ ) { |
| 1257 |
|
if ( !$this->tableExists( $tableName, $fName ) ) { |
| 1258 |
|
return false; |
| 1259 |
|
} |
| 1260 |
|
|
| 1261 |
|
return $this->query( "DROP TABLE IF EXISTS " . $this->tableName( $tableName ), $fName ); |
| 1262 |
|
} |
| 1263 |
|
|
| 1264 |
|
/** |
| 1265 |
|
* Get status information from SHOW STATUS in an associative array |