From 4e40d5a049cfcdb0d5cf3900e20ef6701046d099 Mon Sep 17 00:00:00 2001 From: Tim Starling Date: Sun, 24 Oct 2004 08:04:18 +0000 Subject: [PATCH] Fixing behaviour with a table prefix --- maintenance/parserTests.php | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) 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"); -- 2.20.1