How to get Hostname and IP Address via SQL in Oracle DB and Viceversa

Posted on: 2022-04-19 09:54:25


SQL> SELECT UTL_INADDR.get_host_address from dual;

 

GET_HOST_ADDRESS
--------------------------------------------------------------------------------
172.24.201.11

 

SQL> SELECT UTL_INADDR.get_host_name('172.24.201.11') FROM dual;

 

UTL_INADDR.GET_HOST_NAME('172.24.201.11')
--------------------------------------------------------------------------------
cgreodb1nprd.canonhosted.net
 



xedok When seeking the best software development companies Xedok Software is your ultimate choice. For Demos click here



Leave a reply