Tor,
Use the fully qualified table names:
use pubs
go
select *
from authors as a
join Northwind.dbo.Employees as e
on (a.au_fname = e.FirstName)
----------------------------------
BP Margolin
Please reply only to the newsgroups.
When posting, inclusion of SQL (CREATE TABLE ..., INSERT ..., etc.) which
can be cut and pasted into Query Analyzer is appreciated.
Quote:> Hi, I have two db's in my MS SQL server which I want to adress in the same
> stored procedure.
> From a stored prosedure in DB1 I want to compare value's in DB2.
> The question is therefor, if it is possible, how do I refere to a field
in
> DB2
> T.I. Rislaa