Connecting to another Oracle Server [message #318195] |
Tue, 06 May 2008 01:32 |
monasingh
Messages: 229 Registered: May 2006 Location: Mumbai
|
Senior Member |
|
|
Hi,
I have to create a procedure where I have do some inserts from a table present on database on another oracle server, where the database servername might change at times.
I do not have to use dblink as that would be static and in my case the service name might change at some intervals.
I am thinking of passing the ip address of that server.
Please suggest a way as how and what to pass in the procedure to do the same and if I pass the IP address then how to fetch the table from ip address.
Any suggestion would be highly appreciated.
Thanks in advance,
Mona Singh
|
|
|
Re: Connecting to another Oracle Server [message #318206 is a reply to message #318195] |
Tue, 06 May 2008 02:03 |
|
Michel Cadot
Messages: 68718 Registered: March 2007 Location: Saint-Maur, France, https...
|
Senior Member Account Moderator |
|
|
Whatever change behind the scene, entry name in tnsnames.ora should not. It is the logical level.
In the opposite IP may change, this is why DNS is made for, to hide IP change with a name.
In the same way, tnsnames.ora is made to hide any change on database location or access path, server, port, connect data and so on.
Your database link should be created on tnsnames.ora entry name and so can always access the database.
If tnsnames.ora entry names change then there is a flaw in the name you named them.
Regards
Michel
[Updated on: Tue, 06 May 2008 02:04] Report message to a moderator
|
|
|
|
|