From a478b8164d199e214859ff2a8057ea4bfaf0c5b5 Mon Sep 17 00:00:00 2001 From: Madhura Jayaratne Date: Sat, 15 Oct 2011 16:23:31 +0530 Subject: [PATCH] bug #3299486 [prettyprint] Order By in a query containing comment character --- ChangeLog | 1 + libraries/display_tbl.lib.php | 4 ++-- 2 files changed, 3 insertions(+), 2 deletions(-) diff --git a/ChangeLog b/ChangeLog index 06894fda84..a139e6a43f 100644 --- a/ChangeLog +++ b/ChangeLog @@ -50,6 +50,7 @@ phpMyAdmin - ChangeLog + Support Drizzle database - bug #3356456 [interface] Interface problems for queries having LIMIT clauses + [interface] Remove DefaultPropDisplay feature +- bug #3299486 [prettyprint] Order By in a query containing comment character 3.4.7.0 (not yet released) - bug #3418610 [interface] Links in navigation when $cfg['MainPageIconic'] = false diff --git a/libraries/display_tbl.lib.php b/libraries/display_tbl.lib.php index 45cda6c5ca..5515d5c329 100644 --- a/libraries/display_tbl.lib.php +++ b/libraries/display_tbl.lib.php @@ -928,9 +928,9 @@ function PMA_displayTableHeaders(&$is_display, &$fields_meta, $fields_cnt = 0, $ // It still might be a column name of a view. See bug #3383711 // Check is_orgname. if (strpos($name_to_use_in_sort, '(') !== false && ! $is_orgname) { - $sort_order = ' ORDER BY ' . $name_to_use_in_sort . ' '; + $sort_order = "\n" . 'ORDER BY ' . $name_to_use_in_sort . ' '; } else { - $sort_order = ' ORDER BY ' . $sort_tbl . PMA_backquote($name_to_use_in_sort) . ' '; + $sort_order = "\n" . 'ORDER BY ' . $sort_tbl . PMA_backquote($name_to_use_in_sort) . ' '; } unset($name_to_use_in_sort); unset($is_orgname);