This week's book giveaway is in the OO, Patterns, UML and Refactoring forum.
We're giving away four copies of Refactoring for Software Design Smells: Managing Technical Debt and have Girish Suryanarayana, Ganesh Samarthyam & Tushar Sharma on-line!
See this thread for details.
The moose likes JDBC and Relational Databases and the fly likes Network could not establish connection in jdbc Big Moose Saloon
  Search | Java FAQ | Recent Topics | Flagged Topics | Hot Topics | Zero Replies
Register / Login


JavaRanch » Java Forums » Databases » JDBC and Relational Databases
Bookmark "Network could not establish connection in jdbc" Watch "Network could not establish connection in jdbc" New topic
Author

Network could not establish connection in jdbc

srinivas Doni
Greenhorn

Joined: Jun 02, 2011
Posts: 23
Hi to all,

I am getting error:"Network could not establish connection", while establishing connection to oracle 10g. and os is xp sp2

//code
try {

String jdbcurl = "jdbcracle:thin:@localhost:1521:" + "ORCL";

Class c= Class.forName("oracle.jdbc.driver.OracleDriver");

Driver d = (Driver) c.newInstance();

Properties p = new Properties();
p.put("user", "scott");
p.put("password", "tiger");

Connection con = d.connect(jdbcurl,p);
System.out.println(con);
} catch (Exception e) {
System.out.println("The exception raised is:" + e);
}


if anybody is familar about this, can tell to me.

regards,
srini
 
Have you checked out Aspose?
 
subject: Network could not establish connection in jdbc
 
It's not a secret anymore!