KnowledgeHub
Questions
Tags
Users
Search
Alex Rivera
|
Logout
Edit Question
Title
Body
I have 3 tables: Persons (PersonID, Name, SS) Fears (FearID, Fear) Person_Fear (ID, PersonID, FearID) Now I'd like to list every person with whatever fear is linked to them (can be multiple fears but can also be none). The persons table has to be shown even if a person doesn't have a fear linked to them. I think I need to do a LEFT JOIN, but my code doesn't seem to work: SELECT persons.name, persons.ss, fears.fear FROM persons LEFT JOIN fears ON person_fear.personid = person_fear.fearid What am I doing wrong here?
Tags (comma-separated)
Save Edits
Cancel