From 656df6e610807dea9e2c58bd33f763e0e22f8cdc Mon Sep 17 00:00:00 2001 From: Christopher Burger Date: Sat, 8 Dec 2018 08:55:07 -0500 Subject: [PATCH] RT# 77532 - search count is now correct Conflicts: FS/FS/cust_main/Search.pm --- FS/FS/cust_main/Search.pm | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/FS/FS/cust_main/Search.pm b/FS/FS/cust_main/Search.pm index b1af41c2a..3061b2c12 100644 --- a/FS/FS/cust_main/Search.pm +++ b/FS/FS/cust_main/Search.pm @@ -1143,7 +1143,7 @@ sub search { } - my $count_query = "SELECT COUNT(*) FROM cust_main $addl_from $extra_sql"; + my $count_query = "SELECT COUNT(DISTINCT cust_main.custnum) FROM cust_main $addl_from $extra_sql"; if ($params->{'flattened_pkgs'}) { -- 2.11.0