The correct version of the bad fix I undid in the previous commit. Must explicitly specify all relevant columns in the GROUP BY.

This commit is contained in:
CiaranG 2009-03-05 14:52:35 +00:00
parent 0c066db428
commit ea0c5f565c

View File

@ -57,7 +57,9 @@ class PopularNoticeSection extends NoticeSection
$qry = 'SELECT notice.*, '.
$weightexpr . ' as weight ' .
'FROM notice JOIN fave ON notice.id = fave.notice_id ' .
'GROUP BY notice.id ' .
'GROUP BY notice.id,notice.profile_id,notice.content,notice.uri,' .
'notice.rendered,notice.url,notice.created,notice.modified,' .
'notice.reply_to,notice.is_local,notice.source ' .
'ORDER BY weight DESC';
$offset = 0;