Databases Querying Relational Databases Joining Table Data with SQL JOIN Queries

Richard Külling
Richard Külling
9,463 Points

How does this query not give the correct results?

SELECT Make.MakeName, Model.ModelName, Car.VIN, Car.StickerPrice FROM Model INNER JOIN Make ON Model.ModelID = Model.MakeID INNER JOIN Car ON Car.CarID = Car.ModelID;

1 Answer

KRIS NIKOLAISEN
PRO
KRIS NIKOLAISEN
Pro Student 51,992 Points

You should be joining fields that are the same i.e. ModelID = ModelID, CarID = CarID, etc etc