MySQL很多表连接

post_info table contains many rows (many side) matching a single id. I'm having trouble returning more than one row in my output.

enter image description here

SELECT user.*, post.*, post_info.*, board.* FROM user 
join post ON user.id = post.user_id
join post_info ON post.id = post_info.post_id 
WHERE user.id = 26;

I'm also not sure how to write my board table into the query either.

user table:

enter image description here

post_info table:

enter image description here

post table:

enter image description here

This is how you write you board table into the query. Additional join was added to represent the board to post relationship.

SELECT user.*, post.*, post_info.*, board.* FROM user 
join post ON user.id = post.user_id
join post_info ON post.id = post_info.post_id 
join board ON board.id = post.board_id
WHERE user.id = 26;  

You forgot board table in joins

SELECT 
    board.id     AS board_id,
    post_info.id AS info_id,
    user.id      AS user_id,
    post_id      AS post_id
FROM post
LEFT JOIN post_info ON 
    post_info.post_id=post.id
LEFT JOIN user ON 
    user.id=post.user_id
LEFT JOIN board ON 
    board.id=post.board_id
WHERE user.id = 26