Oracle FAQ | Your Portal to the Oracle Knowledge Grid |
![]() |
![]() |
Home -> Community -> Usenet -> c.d.o.tools -> Re: Is Joining tables from two separate oracle databases possible?
> I'm have oracle 8.1 client installed on my NT box and two databases I
> have access to via tcp/ip and mention in tnsnames.ora. Is there a way
> via sql to access both databases at the same time and do a simple
> join...like lastname to lastname???
>
> If not are there ways of doing this? do I need third party software?
The capability you want is built into Oracle and is called a database link. You create a database link from one instance to the other. Then you can select from either or both instances simultaneously as follows:
SELECT a.field1, b.field2
FROM localtable a, otherinstancetable_at_dblinkname b
WHERE a.field3 = b.field3;
Daniel A. Morgan Received on Wed Feb 28 2001 - 23:32:18 CST
![]() |
![]() |