Hello Everyone,
I am creating an ODBC query to an Access database where the first table
(Listings)
has records for every Listings.ID, but each of the 2 tables I need to join
to it (Addendums and ListingMisc ) may or may not have records with a
matching value in their corresponding field. The following statements work
as expected for one or the other join:
cSelect := SELECT Listings.ID, Listings.Class, Listings.Type,
Addendums.Addendum FROM
Listings LEFT OUTER JOIN Addendums ON (Listings.ID = Addendums.ListingID)
or
cSelect := SELECT Listings.ID, Listings.Class, Listings.Type,
ListingMisc.ListingFeatures1 FROM Listings LEFT OUTER JOIN ListingsMisc ON
(Listings.ID = ListingMisc.ListingID)
oServer1 := SQLSelect{ cSelect, oConn1 }
oServer1:Execute( cSelect )
The above Execute works correctly for either of the cSelect values listed.
How do I combine the Joins? The MS ODBC help file says that both lists and
nested outer joins are supported, but I can't find samples of them and all
my attempts have returned syntax errors either at the FROM level or the JOIN
level.
Help???
Lynn C. Ormond
Lucero Research