From e462ccff4897c2d12e0b9bb445e48a2a3a4222c3 Mon Sep 17 00:00:00 2001 From: Jonathan Druart Date: Mon, 6 May 2019 13:50:54 -0500 Subject: [PATCH] Bug 22812: Fix GROUP BY in checkrouting On the way, let fix this error DBD::mysql::st execute failed: Mixing of GROUP columns (MIN(),MAX(),COUNT(),...) with no GROUP columns is illegal if there is no GROUP BY clause [for Statement "SELECT count(routingid) routingids FROM subscription LEFT JOIN subscriptionroutinglist Test plan: Create a routing list, search for subscriptions In the action list you should see "Edit routing list (1)" or "New routing list" Signed-off-by: Liz Rea --- C4/Serials.pm | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/C4/Serials.pm b/C4/Serials.pm index 1f5a87091e..9f86ab8126 100644 --- a/C4/Serials.pm +++ b/C4/Serials.pm @@ -1884,7 +1884,7 @@ sub check_routing { my $sth = $dbh->prepare( "SELECT count(routingid) routingids FROM subscription LEFT JOIN subscriptionroutinglist ON subscription.subscriptionid = subscriptionroutinglist.subscriptionid - WHERE subscription.subscriptionid = ? ORDER BY ranking ASC + WHERE subscription.subscriptionid = ? GROUP BY routingid ORDER BY ranking ASC " ); $sth->execute($subscriptionid); -- 2.11.0