I am just developing a PHP aplication, and I need a query which involves 4 tables. tables are like:
news {news_pk, user, description, building_pk}
building {building_pk, area_pk, description}
area {area_pk,state_pk}
states {state_pk, name}
I would like to show results filtered by state name (or what I think is the same state_pk
).
I would like to show news from a certain state.
I am not using MySQL so often, but in this app I am doing several queries like this and I am not sure if the inner join is a good solution.
Which query could be the most effective to show only news from a certain state?