SELECT `xf_profile_post`.*, `xf_user_User_1`.*
FROM `xf_profile_post`
LEFT JOIN `xf_user` AS `xf_user_User_1` ON (`xf_user_User_1`.`user_id` = `xf_profile_post`.`user_id`)
WHERE (`xf_profile_post`.`profile_user_id` = 49) AND ((`xf_profile_post`.`message_state` IN ('visible')))
ORDER BY `xf_profile_post`.`post_date` DESC
LIMIT 20