How is the backend of Weibo comment list implemented?

the two comments with the most likes attached to each comment are how to achieve the backend and how to ask for a great solution with high efficiency

Aug.06,2021

Database one-to-many relationship.

main comment table: zmemoridpr _ user _ journal _ textTimmy
sub-comment table: < _

determine the relationship between comments through z_id and display them selectively.

rank sub-comments by the number of likes given by order by, and get the first two comments through limit.

Menu