我有3张桌子:
问题是我要从电影表中选择category_id = 3的所有filmname
。
如何做这个mysql select?
答案 0 :(得分:4)
select
film.filmname
from
film
join film_category
on film.film_id = film_category.film_id
where
film_category.category_id = 3
答案 1 :(得分:0)
SELECT filmname
FROM film NATURAL JOIN film_category
WHERE category_id = 3