I have the following tables in an SQL DB
Vehicles, RepairCharges, TowCharges,
There will always be only 1 record for Vehicle, but multiple records for the other tables. My current LEFT OUTER Join works however if there are multiple entries in the joined tables then its returning just as many rows.
My question is, I need to create a SQL view that will JOIN these tables, however only return a single record for the Vehicle Table, even if there are multiple records in the joined tables. Is this possible with a VIEW, or do i have to use a different approach ?
EDIT: From the answers, I realize as I originally thought, this would not be possible by design. Given the same scenario, how would you approach this ?
The end result is to have a table showing 1 line for each vehicle and in that same line show the first towing and repair charges, then if there were more towing or repair charges, show a new line for each of these, without duplicating the vehicle information.