Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations derfloh on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

DB Relationship

Status
Not open for further replies.

guymanager

Technical User
Joined
Apr 4, 2004
Messages
1
Location
KW
Hi,

How to make a relationship between two Databases ? For ex :

DBName : DB1
TableName: tblPrj
FieldName: Prjcode

DBName : DB2
TableName: prjAccts
FieldName: prjcode

Now is there any posibilities that i can make a relationship between the two databases referencing the field PrjCode , pls guide me if any one have idea abt this.

Thanks,
guymanager.
 
Assuming the 2 db's are on the same SQL server:

select P.Prjcode, A.prjcode
from DB1..tblPrj P
inner join DB2..prjAccts A
on P.Prjcode = A.prjcode
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top