Subject Re: [firebird-support] Re: Upgrading Firebird 1.54 to 2.03 - Query plan
Author Woody
Adam wrote:
> --- In firebird-support@yahoogroups.com, Woody <woody-tmw@...> wrote:
>
>> Rewrite the query using newer join syntax:
>> Choose the correct join type for your situation (left, right, etc.)
>>
>> select J.JOB_ID,
>> J.JOB_NUMBER,
>> C.SHORT_NAME as CUSTOMER_NAME,
>> B.BRANCH_NAME,
>> S.DESCRIPTION as JOB_STATUS,
>> J.CUST_REF_NO
>> from JOB J
>> left join CUSTOMER C on (C.CUSTOMER_ID = J.CUSTOMER_ID)
>> left join BRANCH B on (B.BRANCH_ID = J.BRANCH_ID)
>> left join JOBSTATUS S on (S.JOB_STATUS_CODE = J.JOB_STATUS_CODE)
>> where (J.JOB_ID LIKE '544%')
>> order by J.JOB_ID DESCENDING
>>
>
> Except the equivalent would be an inner join rather than a left outer
> join in this case.

Which is why I wrote: "Choose the correct join type for your
situation" above the query example. :-)

Woody (TMW)