A friendly place for programming greenhorns!
Big Moose Saloon
Register / Login
Difference in Connection Strings for the same DB(Oracle 9i)
Joined: May 22, 2009
Jan 05, 2010 15:33:47
When I connect to Oracle 9i using
I use the connection
Class.forName("oracle.jdbc.driver.OracleDriver"); con=DriverManager.getConnection( "jdbc:oracle:thin:@WIN-6DRGRVTEEUI:1521:ORCL", "admin", "passcode");
And when using
ORCL= (DESCRIPTION= (ADDRESS= (PROTOCOL=TCP) (HOST=WIN-6DRGRVTEEUI.home) (PORT=1521) ) (CONNECT_DATA= (SERVER=dedicated) (SERVICE_NAME=orcl) ) )
Why can't I connect using the First connection String in my WSAD?
Joined: Sep 01, 2005
Jan 05, 2010 23:52:25
First one is a
string, second one is tnsnames entry string. I barely know nothing about WSAD but jdbc approach is the one that is common in
world. tnsnames support may be an implementation detail specific to vendor(IBM).
What difference does it make?
I agree. Here's the link:
subject: Difference in Connection Strings for the same DB(Oracle 9i)
problem in connecting to oracle database.
not able to connect with 10g
All times are in JavaRanch time: GMT-6 in summer, GMT-7 in winter
| Powered by
Copyright © 1998-2014