Posted by Simon Hayes on 10/01/15 11:27
michaelnewport@yahoo.com wrote:
> Simon Hayes schreef:
>
>
>>If you got no rows, is it possible that your subquery result included a
>>NULL? NOT IN combined with a NULL returns an empty set; NOT EXISTS
>>returns all the non-NULL values. Google for 'sql "not in vs not
>>exists"' or something similar and you'll find plenty of discussions
>>about this.
>>
>>Simon
>
>
> I owe you some beer !
> I found some NULL values and some other things I didn't expect, but I'm
> still digesting....
>
> I see (from your example and my practice) that I can only do 1 INNER
> JOIN statement per table and the rest of the joins on that table are
> back to 'old style'. Is there a good reason for that ?
>
The query I posted is a correlated subquery, not a join (as Erland
noted) - see "Correlated Subqueries" in Books Online. But the beer would
still be welcome :-)
Simon
Navigation:
[Reply to this message]
|