I have re-invented the wheel and made my own forum , now I am trying to get the last post from each board in one query. Every option I tried did not work.

I want it to get all the details about the last post in only one query.

1st try:
SELECT bo_id, th_id, th_lastreply_id, MAX(th_lastreply), UNIX_TIMESTAMP(th_lastreply) unix_time, me_user_id, user_nick FROM cgbb_thread, cgbb_users, cgbb_newmessage, cgbb_board WHERE bo_active = 1 AND me_id = th_lastreply_id AND user_id = me_user_id AND th_bo_id = bo_id GROUP BY bo_id order by bo_ca_id, bo_id

It returns the maximum date, but other fields are the first one.

2nd try:

SELECT bo_id, th_id, th_lastreply_id, th_lastreply, UNIX_TIMESTAMP(th_lastreply) unix_time, me_user_id, user_nick FROM cgbb_thread, cgbb_users, cgbb_newmessage, cgbb_board WHERE bo_active = 1 AND me_id = th_lastreply_id AND user_id = me_user_id AND th_bo_id = bo_id GROUP BY bo_id HAVING MAX(th_lastreply) order by bo_ca_id, bo_id

This one does not return any rows at all.

Any help will be approciated.