Accessing a table from a different database [message #340305] |
Tue, 12 August 2008 04:48  |
ramanajv1968
Messages: 168 Registered: December 2005 Location: HYDERABAD
|
Senior Member |
|
|
Hi,
How can we access a table which is in different database.
for e.g., Table "X" is present in Database name: "P1".
Now , I want to access this table from database "P2" .
Both P1 and P2 are oracle databases only.
how can I achieve this.
Thanks,
|
|
|
|
Re: Accessing a table from a different database [message #340330 is a reply to message #340305] |
Tue, 12 August 2008 06:22   |
ramanajv1968
Messages: 168 Registered: December 2005 Location: HYDERABAD
|
Senior Member |
|
|
Thanks,
I created a DBlink and I am using it for select/query the data in one of the Procedure.but,will it have any performance overhead?
Which is the best way
1)Querying the datbase from the JDBC and retrive the results
or 2)by using the dblink ?
Thanks,
|
|
|
|
|
|
|
|
|
Re: Accessing a table from a different database [message #340426 is a reply to message #340330] |
Tue, 12 August 2008 16:13  |
 |
Littlefoot
Messages: 21823 Registered: June 2005 Location: Croatia, Europe
|
Senior Member Account Moderator |
|
|
Perhaps you might also consider use of materialized view (if possible); doing so, you'd have all data in your local database and queries might run quite fast (if compared to ones that run over a database link).
|
|
|