Merge remote-tracking branch 'origin/QA_4_0' into QA_4_0
This commit is contained in:
commit
bed36d8711
@ -105,6 +105,7 @@ underscore
|
||||
- bug #3860 Displayed git revision info is not set
|
||||
- bug #3871 Check referential integrity broken across databases
|
||||
- bug #3874 [export] No preselected option when exporting table
|
||||
- bug #3873 Can't copy table to target database if table exists there
|
||||
|
||||
3.5.9.0 (not yet released)
|
||||
|
||||
|
||||
@ -840,8 +840,8 @@ class PMA_Table
|
||||
$sql_structure = PMA_SQP_formatHtml($parsed_sql, 'query_only');
|
||||
// If table exists, and 'add drop table' is selected: Drop it!
|
||||
$drop_query = '';
|
||||
if (isset($GLOBALS['drop_if_exists'])
|
||||
&& $GLOBALS['drop_if_exists'] == 'true'
|
||||
if (isset($_REQUEST['drop_if_exists'])
|
||||
&& $_REQUEST['drop_if_exists'] == 'true'
|
||||
) {
|
||||
if (PMA_Table::isView($target_db, $target_table)) {
|
||||
$drop_query = 'DROP VIEW';
|
||||
|
||||
@ -541,11 +541,11 @@ function PMA_handleTheViews($views, $move, $db)
|
||||
$_error = false;
|
||||
// temporarily force to add DROP IF EXIST to CREATE VIEW query,
|
||||
// to remove stand-in VIEW that was created earlier
|
||||
// ( $GLOBALS['drop_if_exists'] is used in moveCopy() )
|
||||
if (isset($GLOBALS['drop_if_exists'])) {
|
||||
$temp_drop_if_exists = $GLOBALS['drop_if_exists'];
|
||||
// ( $_REQUEST['drop_if_exists'] is used in moveCopy() )
|
||||
if (isset($_REQUEST['drop_if_exists'])) {
|
||||
$temp_drop_if_exists = $_REQUEST['drop_if_exists'];
|
||||
}
|
||||
$GLOBALS['drop_if_exists'] = 'true';
|
||||
$_REQUEST['drop_if_exists'] = 'true';
|
||||
|
||||
foreach ($views as $view) {
|
||||
$copying_succeeded = PMA_Table::moveCopy(
|
||||
@ -556,10 +556,10 @@ function PMA_handleTheViews($views, $move, $db)
|
||||
break;
|
||||
}
|
||||
}
|
||||
unset($GLOBALS['drop_if_exists']);
|
||||
unset($_REQUEST['drop_if_exists']);
|
||||
if (isset($temp_drop_if_exists)) {
|
||||
// restore previous value
|
||||
$GLOBALS['drop_if_exists'] = $temp_drop_if_exists;
|
||||
$_REQUEST['drop_if_exists'] = $temp_drop_if_exists;
|
||||
}
|
||||
return $_error;
|
||||
}
|
||||
|
||||
Loading…
Reference in New Issue
Block a user