Answer the question
In order to leave comments, you need to log in
How to join multiple tables on one field?
There is a working request. It will append to main_tbl2 an additional table dopstr_tbl2 with a comparison field marker_dop
SELECT `main_tbl2`.*, `dopstr_tbl2`.* FROM `main_tbl2`
LEFT JOIN `dopstr_tbl2` ON `main_tbl2`.`alias` = `dopstr_tbl2`.`marker_dop`
Answer the question
In order to leave comments, you need to log in
The same as with the dopstr_tbl2 table.
SELECT
`main_tbl2`.*,
`dopstr_tbl2`.*,
`dopstr_tbl3`.*
FROM `main_tbl2`
LEFT JOIN `dopstr_tbl2` ON `main_tbl2`.`alias` = `dopstr_tbl2`.`marker_dop`
LEFT JOIN `dopstr_tbl3` ON `main_tbl2`.`alias` = `dopstr_tbl3`.`marker_dop`
Didn't find what you were looking for?
Ask your questionAsk a Question
731 491 924 answers to any question