Database Administrators Stack Exchange is a question and answer site for database professionals who wish to improve their database skills and learn from others in the community. It's 100% free, no registration required.

Sign up
Here's how it works:
  1. Anybody can ask a question
  2. Anybody can answer
  3. The best answers are voted up and rise to the top

On my desktop I have an Oracle client and and Oracle ODAC installed in different homes. I need ODAC because there ADO components off the Client installation don't work correct with CLOB data.

I think I can't go without the client installation, because I need some odbc components.

Now I have to maintain to copies of the tnsnames.ora file. The nest thing I know to do is carefully keep the both tnsnames.ora in sync.

Are there better solutions for a scenario like this?

share|improve this question
up vote 8 down vote accepted

Assuming that you don't want multiple tnsnames.ora files, the simplest option would be to set the TNS_ADMIN environment variable to point at the one tnsnames.ora file you wanted to maintain on the machine. All the Oracle Homes on the machine would then use the tnsnames.ora file in the directory specified by the TNS_ADMIN setting before looking for an entry in the local Oracle Home's tnsnames.ora file.

share|improve this answer
    
+1 That sounds very promising. Going to check it, when I'm back at work. – bernd_k Jun 6 '11 at 18:03

I have felt your pain, as I probably have 3 or 4 Oracle Homes on my PC, so I have created a tool that will sync and update tnsnames across all of the oracle homes.

You can essentially place your "master" tnsnames into a folder of your choosing where you'll keep it up-to-date, and then schedule the tool to run through the windows task scheduler as frequently as you want, or run it manually on demand.

The documentation is in the readme here: https://github.com/artybug/TNSNamesSync/blob/master/README.md

The executable is here: https://github.com/artybug/TNSNamesSync/releases

share|improve this answer
2  
It would probably be more helpful if you give a brief description of how to use your tool to solve the OP's problem. – Erik Mar 26 at 2:51
    
... and a README on the repo! – dezso Mar 26 at 9:22
    
The readme on the repo explains how it can be used. – artybug Mar 26 at 12:45
    
Erik, thanks for the suggestion. I have edited my post to be more specific. – artybug Mar 26 at 12:53

On windows Oracle Locator Express is a simple (and free) tool to handle setting the oracle home and/or the TNS_ADMIN environment variable.

share|improve this answer
    
I would really prefer, to install all the components into one Oracle folder, than to have to switch homes. – bernd_k Jun 7 '11 at 13:04
    
@bernd_k I understand, this was just something that might help in some small way. – Leigh Riffel Jun 7 '11 at 15:26
    
@Leight Riffel. It's OK. In some cases one wants to evaluate different client releases and than is the hour for such tools. – bernd_k Jun 7 '11 at 15:35

Your Answer

 
discard

By posting your answer, you agree to the privacy policy and terms of service.

Not the answer you're looking for? Browse other questions tagged or ask your own question.