Кому интересна судьба этого запроса, то я пришёл к такому решению
SELECT
p.title, p.supplement, p.link, p.file, uPost.avatar, p.pid, uPost.lastname,
CONCAT(IFNULL(uPost.firstname, ''), ' ', IFNULL(uPost.surname, '')) AS name,
uPost.uid,
GROUP_CONCAT(distinct JSON_ARRAY(
JSON_OBJECT(
'name', CONCAT(IFNULL(uComm.firstname, ''), " ", IFNULL(uComm.surname, '')),
'avatar', uComm.avatar,
'lastname', uComm.lastname,
'value', c.value,
'cid', c.cid,
'isAnswer', IFNULL(c.answer, false),
'answers', (SELECT GROUP_CONCAT(JSON_ARRAY(JSON_OBJECT(
'name', CONCAT(IFNULL(uComm.firstname, ''), " ", IFNULL(uComm.surname, '')),
'avatar', uComm.avatar,
'lastname', uComm.lastname,
'value', commAnswer.value,
'cid', commAnswer.cid
))) AS answer FROM comments commAnswer WHERE commAnswer.answer = c.cid)
)
)) AS comments
FROM posts p
JOIN users uPost ON p.uid = uPost.uid AND p.pid = ?
LEFT JOIN comments c ON c.pid = ?
LEFT JOIN users uComm ON uComm.uid = c.uid