I need to get information from 3 tables in an MDB file.
I need all the columns in the first table.
I need 2 columns in the 2nd table where it's primary key matches a
column in the first table.
I need several columns in the 3rd table where it's primary key matches a
column in the 2nd table.
I tried this:
SELECT calPackage.*,calShipment.m_shipDateTime,
calShipment.m_foreignKey00,calPkgAgent.m_residenti al,
calPkgAgent.m_StreetAddress,calPkgAgent.m_City,
calPkgAgent.m_StateProv,calPkgAgent.m_Country,
calPkgAgent.m_PostalCode,calPkgAgent.m_RoomFloor,
calPkgAgent.m_Department,calPkgAgent.m_Attention,
calPkgAgent.Sm_businessName
FROM calPackage
INNER JOIN calShipment
ON calShipment.m_primaryKey=calPackage.m_foreignKey
INNER JOIN calPkgAgent
ON calPkgAgent.m_primaryKey=calShipment.m_foreignKey0 0
but when I tried to execute the command, I get:
Syntax error (missing operator) in query expression
'calShipment.m_primaryKey=calPackage.m_foreignKey INNER JOIN calPkgAgent
ON calPkgAgent.m_primaryKey=calShipment.m_foreignKey0 0'.
I'm looking for any help I can get. Thanks!
*** Sent via Developersdex http://www.developersdex.com ***