Topic: Search - Recent Posts
Our Recent Posts search is slow as shown: Generated in 4.076 seconds, 4 queries executed
Is this search affected by the number of posts?
You are not logged in. Please login or register.
PunBB Forums → PunBB 1.3 troubleshooting → Search - Recent Posts
Our Recent Posts search is slow as shown: Generated in 4.076 seconds, 4 queries executed
Is this search affected by the number of posts?
Is this on MySQL or another DBMS?
Oh, and enable PUN_SHOW_QUERIES and post the slow query.
MySQL 5.0.45
Time: 4.02459
SELECT t.id AS tid, t.poster, t.subject, t.last_post, t.last_post_id, t.last_poster, t.num_replies, t.closed, t.forum_id, f.forum_name FROM punbb_topics AS t INNER JOIN punbb_posts AS p ON p.topic_id=t.id INNER JOIN punbb_forums AS f ON f.id=t.forum_id LEFT JOIN punbb_forum_perms AS fp ON (fp.forum_id=f.id AND fp.group_id=2) WHERE (fp.read_forum IS NULL OR fp.read_forum=1) AND p.posted>1202405009 AND t.moved_to IS NULL GROUP BY t.id ORDER BY t.last_post DESC
Hmm, I wonder if there's a reason we're joining the posts table in...
There doesn't seem to be any reason to join in the posts table, as the last post time is stored in the topic table anyway.
That's what I'm thinking
I noticed Smartys committed a fix for this. Did it help qubertman?
Yes. Thank you!
PunBB Forums → PunBB 1.3 troubleshooting → Search - Recent Posts
Powered by PunBB, supported by Informer Technologies, Inc.