• Using the information given you can do something like this

    SELECT *

    FROM OneDatabase.dbo.EmployeeLocation el

    JOIN SomeDatabase.dbo.Location l ON el.locationcode = l.locationcode

    JOIN AnotherDatabase.dbo.Employee e ON el.employeeID = e.employeeID

    AND l.locationID = e.locationID

    You need to change the names of the databases and include the fields that you need insteadof the asterisk.

    I'm assuming that your databases are on the same server.

    Luis C.
    General Disclaimer:
    Are you seriously taking the advice and code from someone from the internet without testing it? Do you at least understand it? Or can it easily kill your server?

    How to post data/code on a forum to get the best help: Option 1 / Option 2