Welcome to the Treehouse Community
Want to collaborate on code errors? Have bugs you need feedback on? Looking for an extra set of eyes on your latest project? Get support with fellow developers, designers, and programmers of all backgrounds and skill levels here with the Treehouse Community! While you're at it, check out some resources Treehouse students have shared here.
Looking to learn something new?
Treehouse offers a seven day free trial for new students. Get access to thousands of hours of content and join thousands of Treehouse students and alumni in the community today.
Start your free trialGustavo Winter
Courses Plus Student 27,382 PointsWhat is the difference between this two Queries ? Sqlite
I see this two method here at Treehouse.
SELECT MakeName, ModelName FROM make
INNER JOIN model ON make.MakeID = model.MakeID;
------------------------------------------------------------------
SELECT MakeName, ModelName FROM make, model WHERE make.MakeID = model.MakeID;
They got the same result. What is better to use ? Which on is the "best prattice" ?
1 Answer
Dave StSomeWhere
19,870 PointsThis is one of those debated items with probably good support for both sides.
I'm in the use the JOIN/ON camp.
I think it is more readable, easier to understand and allows you to easily change join types (like INNER to OUTER).
Try a quick search and you'll see quite a bit of chatter - I agree with this StackOverflow Question/Answer even if it is pretty old.