summaryrefslogtreecommitdiff
path: root/maintenance/cleanupTable.inc
diff options
context:
space:
mode:
Diffstat (limited to 'maintenance/cleanupTable.inc')
-rw-r--r--maintenance/cleanupTable.inc3
1 files changed, 2 insertions, 1 deletions
diff --git a/maintenance/cleanupTable.inc b/maintenance/cleanupTable.inc
index 67a32510..f63c6d74 100644
--- a/maintenance/cleanupTable.inc
+++ b/maintenance/cleanupTable.inc
@@ -101,7 +101,8 @@ class TableCleanup extends Maintenance {
}
$table = $params['table'];
- $count = $dbr->selectField( $table, 'count(*)', $params['conds'], __METHOD__ );
+ // count(*) would melt the DB for huge tables, we can estimate here
+ $count = $dbr->estimateRowCount( $table, '*', '', __METHOD__ );
$this->init( $count, $table );
$this->output( "Processing $table...\n" );