Re: Outer Join Question
Re: Outer Join Question
- Subject: Re: Outer Join Question
- From: Ricardo Strausz <email@hidden>
- Date: Wed, 30 Apr 2003 16:46:32 -0600
If I understud, you have 3 entities related as follows:
P<-->>S<-->A (where the letters stand for the first letter of the
entities names).
But in your SQL, it seems that there is a 4th table named Restaurants.
The generated SQL can be resumed as:
select * from Rest where A.day = 4 and A.start<=68400000 and
A.close>=68400000 and S.date="apr 30 2003" and S.seat>=3 and A.s = S.id
and Rest.p = P.id
This request should find two persons. One have an availability record
for the date I look for, and the other have a service for that time
period, but no availability record.
First, in the sql, there is no relation between S and P (so it is a
miracle that it finds at least one). This makes me to ask:
Did you double-check the realition S->P??
and,
What is the roll of Rest.?? is it a one-to-one to P??
Dino
http://homepage.mac.com/strausz
_______________________________________________
webobjects-dev mailing list | email@hidden
Help/Unsubscribe/Archives: http://www.lists.apple.com/mailman/listinfo/webobjects-dev
Do not post admin requests to the list. They will be ignored.