From: Tim Starling Date: Sun, 24 Oct 2004 08:04:18 +0000 (+0000) Subject: Fixing behaviour with a table prefix X-Git-Tag: 1.5.0alpha1~1469 X-Git-Url: https://git.cyclocoop.org/admin/?a=commitdiff_plain;h=4e40d5a049cfcdb0d5cf3900e20ef6701046d099;p=lhc%2Fweb%2Fwiklou.git Fixing behaviour with a table prefix --- diff --git a/maintenance/parserTests.php b/maintenance/parserTests.php index 548fd9e57d..1520502185 100644 --- a/maintenance/parserTests.php +++ b/maintenance/parserTests.php @@ -341,11 +341,11 @@ class ParserTest { # "CREATE TEMPORARY TABLE ... SELECT * FROM ... LIMIT 0" # would not create the indexes we need.... foreach ($tables as $tbl) { - $res = $db->query("SHOW CREATE TABLE $tbl"); + $res = $db->query("SHOW CREATE TABLE {$this->oldTableNames[$tbl]}"); $row = $db->fetchRow($res); $create = $row[1]; $create_tmp = preg_replace('/CREATE TABLE `(.*?)`/', 'CREATE TEMPORARY TABLE `' - . $wgDBprefix . '\\1`', $create); + . $wgDBprefix . $tbl .'`', $create); if ($create === $create_tmp) { # Couldn't do replacement die("could not create temporary table $tbl");