Subject Re: [firebird-support] sql problem
Author Martijn Tonies
Hi,

> I'm using firebird 1.5 rc6 and get unexpected results
> when I execute a query.
>
> My query:
> SELECT
> CONTACT.PK,
> CONTACT_SALUTATION.NAME,
> X.NAME AS XX
> FROM
> CONTACT
> LEFT OUTER JOIN CONTACT_SALUTATION ON (CONTACT.FK_1 =
> CONTACT_SALUTATION.PK)
> LEFT OUTER JOIN CONTACT_SALUTATION X ON (CONTACT.FK_FK2 = X.PK)

You are joining twice - is that what you want?

If not, try:

LEFT OUTER JOIN CONTACT_SALUTATION ON (CONTACT.FK_1 =
CONTACT_SALUTATION.PK AND CONTACT.FK_FK2 = CONTACT_SALUTATION.PK)


With regards,

Martijn Tonies
Database Workbench - developer tool for InterBase, Firebird & MS SQL Server.
Upscene Productions
http://www.upscene.com