Skip to content

HTTPS clone URL

Subversion checkout URL

You can clone with HTTPS or Subversion.

Download ZIP

Loading…

Fix #4030: Fix sort on columns which uses function with column between back quotes. #757

Merged
merged 1 commit into from

3 participants

Hugues Peccatte Coveralls Marc Delisle
Hugues Peccatte
Collaborator

Hi,

I here removed back quotes from "name to use in sort" to be comparable with "sort name".

Coveralls

Coverage Status

Coverage increased (+0.01%) when pulling 3431c6b on Tithugues:fix-4030 into 32b8a06 on phpmyadmin:master.

Marc Delisle lem9 was assigned
Marc Delisle
Owner

Looks fine, thanks.

Marc Delisle lem9 merged commit a1dce2e into from
Hugues Peccatte Tithugues deleted the branch
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
This page is out of date. Refresh to see the latest.
Showing with 4 additions and 0 deletions.
  1. +4 −0 libraries/DisplayResults.class.php
4 libraries/DisplayResults.class.php
View
@@ -1979,6 +1979,10 @@ private function _isInSorted(
$new_sort_expression_nodirection = $sort_expression_nodirection;
}
+ //Back quotes are removed in next comparison, so remove them from value
+ //to compare.
+ $name_to_use_in_sort = str_replace('`', '', $name_to_use_in_sort);
+
$is_in_sort = false;
$sort_name = str_replace('`', '', $sort_tbl) . $name_to_use_in_sort;
Something went wrong with that request. Please try again.