From a1d13b913fedaa045dbfb39367cd068c1798c497 Mon Sep 17 00:00:00 2001 From: "bbaetz%student.usyd.edu.au" Date: Thu, 4 Apr 2002 04:21:56 +0000 Subject: [PATCH] Bug 127200 - query for cc takes long time r=mattyt, justdave git-svn-id: svn://10.0.0.236/trunk@118079 18797224-902f-48f8-a5cc-f745e15eee43 --- mozilla/webtools/bugzilla/buglist.cgi | 11 +++++++---- 1 file changed, 7 insertions(+), 4 deletions(-) diff --git a/mozilla/webtools/bugzilla/buglist.cgi b/mozilla/webtools/bugzilla/buglist.cgi index 5863285cf5d..e4e4bbb56d1 100755 --- a/mozilla/webtools/bugzilla/buglist.cgi +++ b/mozilla/webtools/bugzilla/buglist.cgi @@ -502,9 +502,12 @@ sub GenerateSQL { }, "^cc," => sub { - push(@supptables, - ("LEFT JOIN cc cc_$chartid ON bugs.bug_id = cc_$chartid.bug_id LEFT JOIN profiles map_cc_$chartid ON cc_$chartid.who = map_cc_$chartid.userid")); - $f = "map_cc_$chartid.login_name"; + push(@supptables, "cc cc_$chartid"); + push(@wherepart, "bugs.bug_id = cc_$chartid.bug_id"); + + push(@supptables, "profiles map_cc_$chartid"); + push(@wherepart, "cc_$chartid.who = map_cc_$chartid.userid"); + $f = "map_cc_$chartid.login_name"; }, "^long_?desc,changedby" => sub { @@ -616,7 +619,7 @@ sub GenerateSQL { my $attachtable = "attachments_$chartid"; my $statustable = "attachstatuses_${chartid}_$statusid"; - + push(@supptables, "attachments $attachtable"); my $join = "LEFT JOIN attachstatuses $statustable ON ". "($attachtable.attach_id = $statustable.attach_id AND " .