• But it is still not row-by-row, if by that it would mean "as opposed to being set based". You are talking about the physical implementation. In fact, take a look at the execution plan details. If the physical operator for the outer join that both of the queries above results in is a Nested Loop (depending on the data and indexes etc it might choose another, such as Hash Match, instead), take a look at the lower of the two inputs to the right of it. Note the Number of executes for both cases...

    One of the problems with SQL and it's implementations, as opposed to how a true RDBMS should function, is that you can write different queries for getting the same result, but they perform differently. Some will be faster and some slower. That is the direct result of mixing the logical and the physical level. As a programmer (the user of the DBMS) I should not be able to tell the DBMS how it should actually produce my result, I should just tell it what I want. The DBMS would then find the best possible way to do produce that result for me.

    Edit: Not really meant to Remi specifically, but to the discussion as a whole.