From 4f2cac32a58905aab7f81071d27248174f932bad Mon Sep 17 00:00:00 2001 From: Jonathan Druart Date: Fri, 10 Jan 2020 11:29:15 +0100 Subject: [PATCH] Bug 24396: Fix Suggestions.t with MySQL 8 # Failed test 'DelSuggestion deletes the correct suggestion' # at t/db_dependent/Suggestions.t line 413. # got: 'my title 3' # expected: 'my deleted title' t/db_dependent/Suggestions.t .. 112/113 # Looks like you failed 1 test of 113. Suggestions were returned in the reverse order. Adding an ORDER BY clause fixes the problem. Test plan: % prove t/db_dependent/Suggestions.t must return green Signed-off-by: Martin Renvoize Signed-off-by: Joy Nelson --- C4/Suggestions.pm | 1 + 1 file changed, 1 insertion(+) diff --git a/C4/Suggestions.pm b/C4/Suggestions.pm index 836b13fc42..e99ca37326 100644 --- a/C4/Suggestions.pm +++ b/C4/Suggestions.pm @@ -353,6 +353,7 @@ sub GetSuggestionByStatus { LEFT JOIN categories AS C1 ON C1.categorycode=U1.categorycode LEFT JOIN branches AS B1 on B1.branchcode=U1.branchcode WHERE status = ? + ORDER BY suggestionid }; # filter on branch -- 2.39.5