I am using 3.60 and for some reasons, this query is not updating the column 'threads' in user
PHP Code:
$db->query_write("
UPDATE " . TABLE_PREFIX . "user AS user
SET user.threads =
(
SELECT COUNT(threadid)
FROM " . TABLE_PREFIX . "thread AS thread
LEFT JOIN " . TABLE_PREFIX . "forum AS forum ON forum.forumid = thread.forumid
WHERE visible = 1
AND (forum.options & 4096)
AND user.userid=postuserid
)
");
I tried twice. I tried rebuilding, the column shows zero still. Everything else is perfect.