r62982 MediaWiki - Code Review archive

Repository:MediaWiki
Revision:r62981‎ | r62982 | r62983 >
Date:23:12, 25 February 2010
Author:tstarling
Status:ok
Tags:
Comment:
MFT r62981.
Modified paths:
  • /branches/wmf-deployment/maintenance/storage (modified) (history)
  • /branches/wmf-deployment/maintenance/storage/fixBug20757.php (modified) (history)

Diff [purge]

Index: branches/wmf-deployment/maintenance/storage/fixBug20757.php
@@ -31,6 +31,16 @@
3232
3333 $totalRevs = $dbr->selectField( 'text', 'MAX(old_id)', false, __METHOD__ );
3434
 35+ if ( $dbr->getType() == 'mysql'
 36+ && version_compare( $dbr->getServerVersion(), '4.1.0', '>=' ) )
 37+ {
 38+ // In MySQL 4.1+, the binary field old_text has a non-working LOWER() function
 39+ $lowerLeft = 'LOWER(CONVERT(LEFT(old_text,22) USING latin1))';
 40+ } else {
 41+ // No CONVERT() in MySQL 4.0
 42+ $lowerLeft = 'LOWER(LEFT(old_text,22))';
 43+ }
 44+
3545 while ( true ) {
3646 print "ID: $startId / $totalRevs\r";
3747
@@ -40,7 +50,7 @@
4151 array(
4252 'old_id > ' . intval( $startId ),
4353 'old_flags LIKE \'%object%\' AND old_flags NOT LIKE \'%external%\'',
44 - 'LOWER(CONVERT(LEFT(old_text,22) USING latin1)) = \'o:15:"historyblobstub"\'',
 54+ "$lowerLeft = 'o:15:\"historyblobstub\"'",
4555 ),
4656 __METHOD__,
4757 array(
Property changes on: branches/wmf-deployment/maintenance/storage/fixBug20757.php
___________________________________________________________________
Modified: svn:mergeinfo
4858 Merged /trunk/phase3/maintenance/storage/fixBug20757.php:r62981
Property changes on: branches/wmf-deployment/maintenance/storage
___________________________________________________________________
Added: svn:mergeinfo
4959 Merged /branches/REL1_15/phase3/maintenance/storage:r51646
5060 Merged /trunk/phase3/maintenance/storage:r56213,56215-56216,56218,56325,56334-56336,56338,56340,56343,56345,56347,56350,56862,56867,57154-57447,57541,57916,58151,58219,58633,58816,59478,62981

Past revisions this follows-up on

RevisionCommit summaryAuthorDate
r62981Fix for MySQL 4.0tstarling23:06, 25 February 2010

Status & tagging log