From: Pascal Corpet Date: Fri, 14 Jan 2005 10:50:57 +0000 (+0000) Subject: optimisation de la requete pour les notifications du carnet X-Git-Tag: xorg/old~443 X-Git-Url: http://git.polytechnique.org/?a=commitdiff_plain;h=ad3fa669c6686e1a4326150a8d55a2e3ec5c76b8;p=platal.git optimisation de la requete pour les notifications du carnet git-archimport-id: opensource@polytechnique.org--2005/platal--mainline--0.9--patch-313 --- diff --git a/include/notifs.inc.php b/include/notifs.inc.php index c28cefb..dffb1db 100644 --- a/include/notifs.inc.php +++ b/include/notifs.inc.php @@ -104,7 +104,8 @@ function select_notifs_base($base_watch, $champ_w, $champ_u, $watcher, $watcher_ function select_notifs($wuid, $details, $last, $wflag, $order) { $recent = ($last == 'watch_last'); - $contactflag = "FIND_IN_SET('contacts', q.watch_flags)"; + // équivalent de FIND_IN_SET('contacts', q.watch_flags) mais en plus rapide + $contactflag = "(q.watch_flags=1 OR q.watch_flags=3)"; $where_clause = ""; if ($wuid != 'all')