Is there any function in oracle database to provide the current connected server name (or ip) on which the database is running?
The question in other way,
in oracle tnsnames.ora file I have the following
ORA9 =
(DESCRIPTION =
(ADDRESS_LIST =
(ADDRESS = (PROTOCOL = TCP)(HOST = 192.168.14.208)(PORT = 1521))
(ADDRESS = (PROTOCOL = TCP)(HOST = 192.168.14.209)(PORT = 1521))
)
(CONNECT_DATA =
(SERVICE_NAME = orcl)
)
)
How to know if the connected server ip is 192.168.14.208 or 192.168.14.209 in my application?
Try: