Help to combine 2 requests into one
SELECT id FROM players WHERE player = 'test' SELECT * FROM history WHERE id = id In your case it will be like this:
SELECT h.* FROM `players` p JOIN `history` h ON (h.id=p.id) WHERE (p.player='test') LEFT JOIN assumes that there may be no data in history. Why then in the SELECT section only h.* ? Why print blank lines in the sample, if any? - 4perSource: https://ru.stackoverflow.com/questions/597968/
All Articles