Ticket #17998: 17998_upgrade_limit_show_tables.diff
File 17998_upgrade_limit_show_tables.diff, 695 bytes (added by , 13 years ago) |
---|
-
upgrade.php
1404 1404 } 1405 1405 1406 1406 // Check to see which tables and fields exist 1407 if ($tables = $wpdb->get_col('SHOW TABLES;')) { 1407 if ($tables = $wpdb->get_col('SHOW TABLES WHERE (`Tables_in_' . $wpdb->dbname. '` like "' . $wpdb->prefix . '%") or ' . 1408 '(`Tables_in_' . $wpdb->dbname. '` in ("' . implode('","',$wpdb->tables('global')) . '"));')) { 1408 1409 // For every table in the database 1409 1410 foreach ($tables as $table) { 1410 1411 // Upgrade global tables only for the main site. Don't upgrade at all if DO_NOT_UPGRADE_GLOBAL_TABLES is defined.