Open SQL Developer. Go to Tools -> Preferences -> Databases -> Advanced Then explicitly set the Tnsnames Directory
#### ORACLE12c TEST INSTANCE
#### Server name: 188.8.131.52
(ADDRESS = (PROTOCOL = TCP)(HOST = HOST_NAME)(PORT = 1521))
(SERVICE_NAME = SERVICE_NAME)
SQL Developer will look in the following location in this order for a tnsnames.ora file
- TNS_ADMIN lookup key in the registry
- /etc/tnsnames.ora ( non-windows )
If your tnsnames.ora file is not getting recognized, use the following procedure:
- Define an environmental variable called TNS_ADMIN to point to the folder that contains your tnsnames.ora file.In Windows, this is done by navigating to Control Panel > System > Advanced system settings> Environment Variables…
In Linux, define the TNS_ADMIN variable in the .profile file in your home directory.
- Confirm the os is recognizing this environmental variableFrom the Windows command line: echo %TNS_ADMIN%
From linux: echo $TNS_ADMIN
- Restart SQL Developer
- Now in SQL Developer right click on Connections and select New Connection…. Select TNSas connection type in the drop down box. Your entries from tnsnames.ora should now display here.