SQL joining tables based on IDs -


i have 3 tables;

a title table has columns title_id , title_name.

a team table has columns team_id , team_name

a link table has columns title_id , team_id

i want merge first 2 tables using third 1 (using id fields), since want create table have both title_name , team_name matched accordingly link table. there sql statement ? been trying @ left , right joins can't think of how merge properly. help

select ti.title_name, te.team_name link l inner join title ti on l.title_id = ti.title_id inner join team te on l.team_id = te.team_id 

Comments

Popular posts from this blog

c++ - CryptStringToBinary API behavior -

java.util.scanner - How to read and add only numbers to array from a text file -

iphone - Three second countdown in cocos2d -