I have a little problem - i would can get with this query topics posts count and last post id, but i can't figure out, how to get right user id. I get first post (lowest id) user id but i want lastest post... I have tried adding "ORDER BY id DESC" but this will not help. Any ideas how to do it?
SELECT
COUNT(`id`) AS `count`,
MAX(`id`) AS `last_post_id`,
`topic_id`,
`user_id`
FROM `forum_posts`
WHERE `topic_id` IN (326, 207, 251)
GROUP BY `topic_id`