diff --git a/ChangeLog b/ChangeLog index e22515d366..b2271d23fd 100644 --- a/ChangeLog +++ b/ChangeLog @@ -15,6 +15,7 @@ phpMyAdmin - ChangeLog + Patch #3510656 Contest-1: Ignoring foreign keys while dropping tables 3.5.1.0 (not yet released) +- bug #3510784 [edit] Limit clause ignored when sort order is remembered 3.5.0.0 (not yet released) + rfe #2021981 [interface] Add support for mass prefix change. diff --git a/libraries/common.lib.php b/libraries/common.lib.php index e35f405511..f40f61b343 100644 --- a/libraries/common.lib.php +++ b/libraries/common.lib.php @@ -1120,6 +1120,7 @@ function PMA_showMessage($message, $sql_query = null, $type = 'notice', $is_view ) { $query_base = $analyzed_display_query[0]['section_before_limit'] . "\n" . $GLOBALS['sql_order_to_append'] + . $analyzed_display_query[0]['limit_clause'] . ' ' . $analyzed_display_query[0]['section_after_limit']; // Need to reparse query diff --git a/sql.php b/sql.php index 432fb141b5..952d7ebba3 100644 --- a/sql.php +++ b/sql.php @@ -467,7 +467,7 @@ if ($GLOBALS['cfg']['RememberSorting'] // retrieve the remembered sorting order for current table $sql_order_to_append = ' ORDER BY ' . $sorted_col . ' '; $full_sql_query = $analyzed_sql[0]['section_before_limit'] . $sql_order_to_append - . $analyzed_sql[0]['section_after_limit']; + . $analyzed_sql[0]['limit_clause'] . ' ' . $analyzed_sql[0]['section_after_limit']; // update the $analyzed_sql $analyzed_sql[0]['section_before_limit'] .= $sql_order_to_append;