So I've got a database with 4 tables: artist, genre, track and album. Track table points in a many to one way to Genre table, and so on with Track to Album, and Album to Artist.
Suppose I want to find every genre that 'John Coltrane' plays, so I thought about saying
SELECT DISTINCT Artist.name, Genre.name
FROM Artist
JOIN Genre
JOIN Album
JOIN Track
WHERE Artist.name = 'John Coltrane'
AND Track.genre_id = Genre.genre_id
But this just gives me
i.e. ALL genres jointed to John Coltrane, instead of just 'Jazz' which is what I'm seeking...
Why is it not working?