How to get SQL-rd information from the table on all sides?

Hi! Help, there are two tables, one with user information (e.g. personal data), and the second with their dialogues:

first

| id | email | name |
second

| id | first_id | second_id | msg |


How exactly one query to return information about each user with whom the user with a certain id have a dialogue?
March 12th 20 at 08:03
1 answer
March 12th 20 at 08:05
Solution
select
t1.*,
t2.*
from table1 t1
join table2 t2 on t2.first_id = t1.id
where t2.second_id = 111

Find more questions by tags MySQL