Thanks to You Brent and Bill Easton
and Sorry
Hrmm , that what happen when not clipping direct into mail program ,
here is the Original :-) :
Select A.DepartmentName,A.Address,P.Postcode,P.cityname,CP.firstname
from caddress A,cpostinfo P
left Join CContactPerson CP , caddresscontactperson C
Your syntax is wrong, or at least not standard, if you are trying to do
multiple left joins.
Your ordering is not your typical for a query.
And you say "there" instead of "where".
Your query should be structure like this:
SELECT
FROM , ,...
LEFT JOIN ON
LEFT JOIN ON
LEFT JOIN ON
...
WHERE
on CACP.ContactpersonID=CP.ID and CACP.AddressID=A.ID
left join ccontactinfo CCI
on CACP.ID=CCI.AddressContactPersonID
and CCI.AddressID=-1 and CCI.ContactInfoTypeID=1
where A.ID=10 and A.PostInfoID=P.ID
> Date: Wed, 12 Nov 2003 23:20:10 +0100 (CET)
> Subject: Sql - Proble
Hello
the little Query1 works until I add the left join :
Query 1 )
Select A.DepartmentName,A.Address,P.Postcode,P.cityname
from caddress A,cpostinfo P
there A.ID=10 and A.PostInfoID=P.ID
Query 2)
Select A.DepartmentName,A.Address,P.Postcode,P.cityname,
CP.firstname
left Join CCo