SQLPlus cannot find TNSNAMES.ORA

by Don Del Grande   Last Updated September 11, 2019 17:01 PM

I just uninstalled an older Oracle installation on my computer (which was working fine) and installed a new one, and the new installation can't seem to find the TNSNAMES.ORA file even though it is in the \network\admin folder of the same installation directory as \bin\sqlplus.exe - and SQLPlus works if I connect by entering the IP and SID directly.

Is there some setting that I am missing that points to TNSNAMES.ORA? I always thought it looked in \network\admin by default.

Answers 1

If you uninstall previous Oracle SQL client and reinstall it. There should be multiple folder as below. In windows C:\app\USER\product\ORACLE_CLENT_VERSION\client_INSTANCE-NO\network\admin Replace the upper case string with your computer path.

In Linux, it should be in ./oracle/network/admin folder.

And connection string should be like net_service_name= (DESCRIPTION= (ADDRESS=(protocol_address_information)) (CONNECT_DATA= (SERVICE_NAME=service_name)))

I guess your issue is you are still using previous version client's TNSNAMES.ORA. In the "C:\app\USER\product\ORACLE_CLENT_VERSION\client_INSTANCE-NO\network\admin", first instance installed created a client_1 (client_INSTANCE-NO) folder and second instance created a client_2 folder and so on. You need to ensure you editing latest instance TNSNAMES.ORA.

September 11, 2019 16:41 PM

Related Questions

Updated September 03, 2019 07:01 AM

Updated March 24, 2017 09:01 AM

Updated April 22, 2018 10:01 AM

Updated July 04, 2019 09:01 AM

Updated March 26, 2019 19:01 PM