From 67dd31d83f3088850cf267fb8e2dd34623ef5c5e Mon Sep 17 00:00:00 2001 From: =?utf8?q?St=C3=A9phane=20Jacob?= Date: Mon, 12 Dec 2011 17:13:35 +0100 Subject: [PATCH] Retrieves a single address in adresses dump. MIME-Version: 1.0 Content-Type: text/plain; charset=utf8 Content-Transfer-Encoding: 8bit Signed-off-by: Stéphane Jacob --- include/userset.inc.php | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/include/userset.inc.php b/include/userset.inc.php index 3b18a44..d0b2138 100644 --- a/include/userset.inc.php +++ b/include/userset.inc.php @@ -438,7 +438,8 @@ class AddressesView implements PlView FROM profile_addresses AS pa WHERE pa.pub IN ('public', 'ax') AND FIND_IN_SET('mail', pa.flags) AND pa.pid IN {?} ORDER BY pa.pid, NOT FIND_IN_SET('current', pa.flags), - FIND_IN_SET('secondary', pa.flags), pa.type = 'job') AS pa + FIND_IN_SET('secondary', pa.flags), pa.type = 'job' + LIMIT 1) AS pa INNER JOIN profiles AS p ON (pa.pid = p.pid) INNER JOIN profile_display AS pd ON (pd.pid = pa.pid) INNER JOIN profile_public_names AS pn ON (pn.pid = pa.pid) -- 2.1.4