mirror of
https://github.com/phpbb/phpbb.git
synced 2025-06-19 17:13:31 +02:00
- Significant speed increase, MySQL can't ORDER BY arbitrary statements anyway
git-svn-id: file:///svn/phpbb/trunk@5919 89ea8834-ac86-4346-8a33-228a782c2dd0
This commit is contained in:
@ -817,8 +817,7 @@ class ucp_main
|
|||||||
WHERE p.poster_id = ' . $user->data['user_id'] . "
|
WHERE p.poster_id = ' . $user->data['user_id'] . "
|
||||||
AND f.forum_id = p.forum_id
|
AND f.forum_id = p.forum_id
|
||||||
$post_count_sql
|
$post_count_sql
|
||||||
GROUP BY f.forum_id
|
GROUP BY f.forum_id";
|
||||||
ORDER BY COUNT(p.post_id) DESC";
|
|
||||||
$result = $db->sql_query_limit($sql, 1);
|
$result = $db->sql_query_limit($sql, 1);
|
||||||
$active_f_row = $db->sql_fetchrow($result);
|
$active_f_row = $db->sql_fetchrow($result);
|
||||||
$db->sql_freeresult($result);
|
$db->sql_freeresult($result);
|
||||||
@ -837,8 +836,7 @@ class ucp_main
|
|||||||
AND t.topic_id = p.topic_id
|
AND t.topic_id = p.topic_id
|
||||||
AND f.forum_id = t.forum_id
|
AND f.forum_id = t.forum_id
|
||||||
$post_count_sql
|
$post_count_sql
|
||||||
GROUP BY t.topic_id
|
GROUP BY t.topic_id";
|
||||||
ORDER BY COUNT(p.post_id) DESC";
|
|
||||||
$result = $db->sql_query_limit($sql, 1);
|
$result = $db->sql_query_limit($sql, 1);
|
||||||
$active_t_row = $db->sql_fetchrow($result);
|
$active_t_row = $db->sql_fetchrow($result);
|
||||||
$db->sql_freeresult($result);
|
$db->sql_freeresult($result);
|
||||||
|
Reference in New Issue
Block a user