Oracle FAQ | Your Portal to the Oracle Knowledge Grid |
![]() |
![]() |
Home -> Community -> Usenet -> c.d.o.misc -> Re: Thanks ALEX Filonov
Try this SQL
select distinct customer.name, customer.address, customer.post_code
from customer, car_type, hiring, car
where customer.acc_no = hiring.cust_acc
and hiring.regno = car.regno
and car.model = car_type.model
and maker IN ('Ford', 'Jaguar', 'Vauxhall');
Good Luck.
Mark Thomas пишет в сообщении ...
:thankyou very much for your help - it did the trick
:
:hope you will not mind answering one more for me - i really would
appreciate
:it
:
:question
:
:the names, addresses and postcodes of customers who have hired each make of
:car?
:
:there are 3 makes of car jaguar vauxhall and ford
:when i run the below the computer produces a result of zero.
:i have been told that in my query that it doesn't search 3 times per
:customer and therefore doesn't pick up on my data. - i hope that sort of
:makes sense.
:
:my input is
:
:select distinct customer.name, customer.address, customer.post_code
:from customer, car_type, hiring, car
:where customer.acc_no = hiring.cust_acc
:and hiring.regno = car.regno
:and car.model = car_type.model
:and maker = 'Ford'
:and maker = 'Jaguar'
:and maker = 'Vauxhall';
:
:thanx in advance
:
:mark
:
Received on Thu Mar 23 2000 - 01:10:49 CST
![]() |
![]() |