Solved

Connectivity to Oracle

Posted on 2004-09-06
3
191 Views
Last Modified: 2010-04-01
Hi all, i have expereicen in conecting to IBM Db2, but not oracle,

Can anyone share me the way to connect to oraacle databse.

TQ.

try {

Class.forName("what is the name").newInstance();
Connection conn = DriverManager.getConnection("what is the path");

}

thank you
0
Comment
Question by:spiderman19
  • 2
3 Comments
 
LVL 92

Accepted Solution

by:
objects earned 250 total points
ID: 11987958
0
 
LVL 11

Expert Comment

by:sompol_kiatkamolchai
ID: 11987975
Here is another example

>>Class.forName("what is the name").newInstance();
oracle.jdbc.driver.OracleDriver
>>Connection conn = DriverManager.getConnection("what is the path");
jdbc:oracle:thin:@(description=(address=(host=database_ip)(protocol=tcp)(port=1521))(connect_data=(sid=database_instance_name)))

But make sure you have OracleDriver include to classpath.
0
 
LVL 92

Expert Comment

by:objects
ID: 11992783
thanks mate :)
0

Featured Post

How your wiki can always stay up-to-date

Quip doubles as a “living” wiki and a project management tool that evolves with your organization. As you finish projects in Quip, the work remains, easily accessible to all team members, new and old.
- Increase transparency
- Onboard new hires faster
- Access from mobile/offline

Join & Write a Comment

Suggested Solutions

Restoring deleted objects in Active Directory has been a standard feature in Active Directory for many years, yet some admins may not know what is available.
In this article, you will read about the trends across the human resources departments for the upcoming year. Some of them include improving employee experience, adopting new technologies, using HR software to its full extent, and integrating artifi…
Internet Business Fax to Email Made Easy - With eFax Corporate (http://www.enterprise.efax.com), you'll receive a dedicated online fax number, which is used the same way as a typical analog fax number. You'll receive secure faxes in your email, fr…
You have products, that come in variants and want to set different prices for them? Watch this micro tutorial that describes how to configure prices for Magento super attributes. Assigning simple products to configurable: We assigned simple products…

708 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question

Need Help in Real-Time?

Connect with top rated Experts

13 Experts available now in Live!

Get 1:1 Help Now