views:

6

answers:

0

I have three related tables: People has ID fields for both Organisations and Locations. Locations has an ID field for Organisation. I want the Locations combo box in my People table to show only the Locations that have the Organisation_ID that was entered previously. I tried WHERE but it doesn't seem to recognise the [People].[Organisation_ID] conditon and prompts for it.

SELECT Locations.Location_ID, Locations.Organisation_ID, People.Organisation_ID, Locations.City
FROM Locations INNER JOIN People ON Locations.Location_ID = People.Location_ID
WHERE Locations.Organisation_ID=[People].[Organisation_ID]
ORDER BY Locations.City;

Can someone help? Thanks!!!!