Forum Moderators: open
I'm learning SQL on my own.
I have 1 table which has 2 foreign key columns. Now I have to run a Select query with WHERE cluase which brings all columns together with foreign key tables. How do i get the foreign key columns?
This is the query i'm using at the moment. Is it OK?
select * from gig where gig.gigid = $gigDetail LEFT JOIN genre ON gig.genreId=genre.genreId LEFT JOIN venue ON gig.venueID = venue.vid ORDER BY gig.gigid";
I hope you understand what i'm trying to ask!
Thank you