niiki-lou Posted July 14, 2009 Share Posted July 14, 2009 Hey guys, Just wonder on how i would go about working out the top ten posters on my little forum script in my table i have this Field Type Collation Attributes Null post_id int(250) No author text latin1_swedish_ci Yes post_body text latin1_swedish_ci Yes post_date text latin1_swedish_ci Yes thr_id text latin1_swedish_ci Yes for_id int(250) No So from my guess ill need to get author from table forum_posts but thats as far as my guess goes ive had a hunt on google but im not sure were i go from here.. Any help is really greatfull. Link to comment https://forums.phpfreaks.com/topic/165951-top-10-posters/ Share on other sites More sharing options...
rhodesa Posted July 14, 2009 Share Posted July 14, 2009 SELECT author, COUNT(*) numPosts FROM tableName GROUP BY author ORDER BY numPosts DESC LIMIT 10 Link to comment https://forums.phpfreaks.com/topic/165951-top-10-posters/#findComment-875269 Share on other sites More sharing options...
Recommended Posts
Archived
This topic is now archived and is closed to further replies.