
01-23-2016, 06:57 AM
|
 |
|
|
Join Date: Oct 2010
Location: iraq
Posts: 122
Благодарил(а): 0 раз(а)
Поблагодарили:
0 раз(а) в 0 сообщениях
|
|
Quote:
Originally Posted by MarkFL
This is the query:
PHP Code:
$myfeatured = $vbulletin->db->query_first("
SELECT COUNT(*) AS thread_count, thread.postuserid
FROM " . TABLE_PREFIX . "thread AS thread
INNER JOIN " . TABLE_PREFIX . "featuredthreads AS featuredthreads
ON thread.threadid = featuredthreads.threadid
WHERE thread.postuserid = " . $post['userid']
);
I use "COUNT" all the time without a "GROUP BY" clause. What MySQL version are you using?
|
version 5.0.51
|