Answer the question
In order to leave comments, you need to log in
How to get an article and all tags with one request?
There is a table of art articles, a table of tag tags and a table of relat which indicate which article which tags refer to.
With one request:
SELECT * FROM `art`
LEFT JOIN `relat`
ON `art`.`id` = `relat`.`tagid`
WHERE `art`.`id` IN (1,2,3,4)
Answer the question
In order to leave comments, you need to log in
`art`.`id` = `relat`.`tagid`
article id = tag id? There is no mistake right?
Didn't find what you were looking for?
Ask your questionAsk a Question
731 491 924 answers to any question