Link to home
Start Free TrialLog in
Avatar of gram77
gram77Flag for India

asked on

Where is pl/slq developer picking up tnsnames.ora

I installed Oracle instant client 11.1

I am able to log into database using command prompt. It picks up the correct tnsnames.ora in folder C:\oracle\instantclient_11_1\TNSNAMES.ora

However, when i use an external tool such as TOAD or Pl/Sql developer it fails to pick up that tnsnames.ora

How do i know which tnsnames.ora is pl/sql developer picking up, and redirect the tool to pick up tnsnames from the above given path?
Avatar of Pratima
Pratima
Flag of India image

In Pl-Sql Developen
Under Help Menu>Support Info

will contain the details of TNS names files like below

TNS File
  C:\OraHome\Network\Admin\tnsnames.ora
Avatar of apresence
apresence

Take a look at your HKEY_LOCAL_MACHINE\SOFTWARE\ORACLE\inst_loc setting and make sure it points to the right place.

The individual home directories you have set up will have sub-keys under there, make sure they exist and are correct as well.
Example registry settings from my system running PL/SQL:
 
SOFTWARE\ORACLE
  inst_loc = C:\Program Files\Oracle\Inventory

  SOFTWARE\ORACLE\KEY_OraClient10g_home1
    ORACLE_HOME = C:\Oracle\product\10.1.0\Client_1
    ORACLE_HOME_NAME = OraClient10g_home1
    ORACLE_GROUP_NAME = Oracle - OraClient10g_home1
    ORACLE_BUNDLE_NAME = Enterprise
    NLS_LANG = AMERICAN_AMERICA.WE8MSWIN1252
    ORACLE_HOME_KEY = SOFTWARE\ORACLE\KEY_OraClient10g_home1

    SOFTWARE\ORACLE\KEY_OraClient10g_home1\ODP.NET
      TraceFileName = C:\ODPNET.trc
      TraceLevel = 0
      TraceOption = 0
      StatementCacheSize = 0

Open in new window

Avatar of gram77

ASKER

sqldeveloper shows oracle homes this way:
Homes
  ORACLE10GODBC  (C:\Program Files\ORACLE10GODBC)
  OraClient10g_home1  (C:\oracle\product\10.2.0\client_1)

I have tnsnames in:
C:\oracle\product\10.2.0\client_1\NETWORK\ADMIN\TNSNAMES.ora

still pl/sql developer is not picking up the file.

I want pl/sql developer to pick up TNSNAMES.ora from 11.1 instantclient:
C:\oracle\instantclient_11_1\TNSNAMES.ora

how do i do this
There obviously isn't an Oracle Home se tup for your 11.1 instant client.  You'll need to set that up.  There are instructions on how to do that here (scroll to the bottom):
http://download.oracle.com/docs/cd/B10500_01/em.920/a96697/moh.htm
ASKER CERTIFIED SOLUTION
Avatar of devind
devind

Link to home
membership
This solution is only available to members.
To access this solution, you must be a member of Experts Exchange.
Start Free Trial
Avatar of gram77

ASKER

I am getting access denied in this path as the folder is write protected, and any attempt to change folder from readonly results in error

C:\Program Files\ORACLE10GODBC\NETWORK\ADMIN

new setting in tools->preferences
oracle home:C:\oracle\instantclient_11_1
oci library: C:\oracle\instantclient_11_1\oci.dll

however still i am getting error, however seems at least it is oracle error:
could not resolve the connect identifier specified
which version of windows you are usind? Do you have admin aCcess?
Avatar of gram77

ASKER

i don't have admin access to my pc, so can't install any software at will
Avatar of gram77

ASKER

all i want to know is when TNSNAMES.ora and oci.dll are present in C:\oracle\instantclient_11_1
and i have provided the explicit path to the toll, why isn't the tool picking them up
Try defining an environment variable TNS_ADMIN and set to the directory of your instant client. Don't tell me you can't do that either :(-
Avatar of gram77

ASKER

thanks newbie, but i don't need your help.
Well, I'm just speculating at this point, but usually the tnsnames.ora file would be located in C:\oracle\instantclient_11_1\network\admin\tnsnames.ora and not C:\oracle\instantclient_11_1.  If you have rights to create those directories, you might try moving it there.
Avatar of gram77

ASKER

apresence:
didn't work
SOLUTION
Link to home
membership
This solution is only available to members.
To access this solution, you must be a member of Experts Exchange.
Start Free Trial