• Status: Solved
  • Priority: Medium
  • Security: Public
  • Views: 106
  • Last Modified:

join seperate databases

How do you join tables that are NOT in the same database (2 different databases)?
0
MBHEY131
Asked:
MBHEY131
1 Solution
 
Daniel WilsonCommented:
Same server or different?  If different servers ... I don't think you can do that.

If it's the same server, include the DB name with the tablenames.

select * from
DbAlpaha.CoolTable C Inner Join DbBeta.WeirdTable W on C.ID = W.ID;

Open in new window

0
 
MBHEY131Author Commented:
Same Server
0

Featured Post

Keep up with what's happening at Experts Exchange!

Sign up to receive Decoded, a new monthly digest with product updates, feature release info, continuing education opportunities, and more.

Tackle projects and never again get stuck behind a technical roadblock.
Join Now