includes/libs/rdbms/database/DatabaseSqlite.php 1 location
|
@@ 1040-1047 (lines=8) @@
|
| 1037 |
|
* @return bool|ResultWrapper |
| 1038 |
|
* @throws DBReadOnlyError |
| 1039 |
|
*/ |
| 1040 |
|
public function dropTable( $tableName, $fName = __METHOD__ ) { |
| 1041 |
|
if ( !$this->tableExists( $tableName, $fName ) ) { |
| 1042 |
|
return false; |
| 1043 |
|
} |
| 1044 |
|
$sql = "DROP TABLE " . $this->tableName( $tableName ); |
| 1045 |
|
|
| 1046 |
|
return $this->query( $sql, $fName ); |
| 1047 |
|
} |
| 1048 |
|
|
| 1049 |
|
protected function requiresDatabaseUser() { |
| 1050 |
|
return false; // just a file |
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
|
@@ 3423-3430 (lines=8) @@
|
| 3420 |
|
* @return bool|ResultWrapper |
| 3421 |
|
* @since 1.18 |
| 3422 |
|
*/ |
| 3423 |
|
public function dropTable( $tableName, $fName = __METHOD__ ) { |
| 3424 |
|
if ( !$this->tableExists( $tableName, $fName ) ) { |
| 3425 |
|
return false; |
| 3426 |
|
} |
| 3427 |
|
$sql = "DROP TABLE " . $this->tableName( $tableName ) . " CASCADE"; |
| 3428 |
|
|
| 3429 |
|
return $this->query( $sql, $fName ); |
| 3430 |
|
} |
| 3431 |
|
|
| 3432 |
|
public function getInfinity() { |
| 3433 |
|
return 'infinity'; |
includes/libs/rdbms/database/DatabaseMysqlBase.php 1 location
|
@@ 1259-1265 (lines=7) @@
|
| 1256 |
|
* @param string $fName |
| 1257 |
|
* @return bool|ResultWrapper |
| 1258 |
|
*/ |
| 1259 |
|
public function dropTable( $tableName, $fName = __METHOD__ ) { |
| 1260 |
|
if ( !$this->tableExists( $tableName, $fName ) ) { |
| 1261 |
|
return false; |
| 1262 |
|
} |
| 1263 |
|
|
| 1264 |
|
return $this->query( "DROP TABLE IF EXISTS " . $this->tableName( $tableName ), $fName ); |
| 1265 |
|
} |
| 1266 |
|
|
| 1267 |
|
/** |
| 1268 |
|
* @return array |