JDBC connection in Oracle iAS

I have developed a web application (jsp) using tomcat 5.5.7 with Oracle 10g as the data base.  I use the oracle thin driver (ojdbc14.jar).  It works fine in tomcat.  I am moving the application to Oracle iAS 10g.  The following lines of code load the driver in tomcat with the ojdbc14.jar under WEB-INF/lib:

DriverManager.registerDriver(new oracle.jdbc.driver.OracleDriver());
Connection conn = DriverManager.getConnection("jdbc:oracle:thin:@", uzr, pwd);

The connection is not working from the Oracle application server.  It gives the following error:

ORA-12505: TNS:listener could not resolve SID given

Can anyone help with this issue?      
Who is Participating?
I wear a lot of hats...

"The solutions and answers provided on Experts Exchange have been extremely helpful to me over the last few years. I wear a lot of hats - Developer, Database Administrator, Help Desk, etc., so I know a lot of things but not a lot about one thing. Experts Exchange gives me answers from people who do know a lot about one thing, in a easy to use platform." -Todd S.

Check the tnsnames.ora files on the ias10g server under your Oracle Homes,


...ensure that they contain entries for your database (orclaac), something like this:

      (ADDRESS = (PROTOCOL = TCP)(HOST = *yourhostname*)(PORT = 1521))
      (SERVICE_NAME = *yourinstancename*)

...amend PORT if necessary

emj345Author Commented:
It was an issue with the SID name.  even though it existed in the tnsnames.ora as orclaac it was not recognized.  The default orcl was the true instance name.  Thanks for your help
PAQed with 500 points refunded

Community Support Moderator

Experts Exchange Solution brought to you by

Your issues matter to us.

Facing a tech roadblock? Get the help and guidance you need from experienced professionals who care. Ask your question anytime, anywhere, with no hassle.

Start your 7-day free trial
It's more than this solution.Get answers and train to solve all your tech problems - anytime, anywhere.Try it for free Edge Out The Competitionfor your dream job with proven skills and certifications.Get started today Stand Outas the employee with proven skills.Start learning today for free Move Your Career Forwardwith certification training in the latest technologies.Start your trial today
Java App Servers

From novice to tech pro — start learning today.