I am working on a similar function that forum had, the number of pages in each forum section.
My thought and functions as follow:
I have completed all the things except the last two things mentioned above. however, the number of pages has been a problem to me. Here's my thought:
Is there any possible solution to implement this function? Or is COUNT(key) is the best approach?
You could add a column to your thread table (something like 'postCount'), and then increment it whenever a post is added to that thread. Then you could use that value to determine the number of pages instead of counting the number of posts each time.