diff --git a/ChangeLog b/ChangeLog index 0a9b3bd795..5c201f6415 100644 --- a/ChangeLog +++ b/ChangeLog @@ -88,6 +88,7 @@ phpMyAdmin - ChangeLog - issue #12615 Fixed regexp for matching browser versions - issue #12569 Avoid showing import errors twice - issue #12362 prefs_manage.php can leave an orphaned temporary file +- issue #12619 Unable to export csv when using union select 4.6.4 (2016-08-16) - issue [security] Weaknesses with cookie encryption, see PMASA-2016-29 diff --git a/tbl_export.php b/tbl_export.php index fd6989d82e..46527133bc 100644 --- a/tbl_export.php +++ b/tbl_export.php @@ -67,7 +67,9 @@ if (! empty($sql_query)) { } // Rebuilding the SELECT and FROM clauses. - if (count($parser->statements[0]->from) > 0) { + if (count($parser->statements[0]->from) > 0 + && count($parser->statements[0]->union) === 0 + ) { $replaces = array( array( 'FROM', 'FROM ' . SqlParser\Components\ExpressionArray::build(