File APIs for Java Developers
Manipulate DOC, XLS, PPT, PDF and many others from your application.
http://aspose.com/file-tools
The moose likes JDBC and the fly likes Getting started with Oracle 11g Express using Eclipse Big Moose Saloon
  Search | Java FAQ | Recent Topics | Flagged Topics | Hot Topics | Zero Replies
Register / Login


Win a copy of Android Security Essentials Live Lessons this week in the Android forum!
JavaRanch » Java Forums » Databases » JDBC
Bookmark "Getting started with Oracle 11g Express using Eclipse" Watch "Getting started with Oracle 11g Express using Eclipse" New topic
Author

Getting started with Oracle 11g Express using Eclipse

Christopher Sharp
Ranch Hand

Joined: Dec 12, 2007
Posts: 152
Hello,

I am new to using JDBC, and wish to test out the connection to an oracle database with Java using Eclipse. Once I can get past this hurdle, I am hoping to move forward more quickly and get Oracle incorporated in an Eclipse projects using JavaServer Faces.

I have Eclipse Indigo Release 2 and Java 1.7 installed on my Windows Vista computer, and have been using JavaServer Faces 2.0 for several months, but now wish to access an Oracle database. A while ago I also installed Oracle Database 11g Express, but it has been sitting dormant until now. In the command DriverManager.getConnection(url) a string is required for url, and I am not clear what information I should provide. The argument of getConnection provided by Oracle is: "jdbc:myDriver:myDatabase", username, password. What should "myDriver" be, and presumably "username" and "password" apply to "myDatabase"?

I am sure this is very elementary, but would most appreciate some help in getting started. Many thanks in advance, and perhaps someone can kindly give some advice on setting up Eclipse to handle database connections.
chris webster
Bartender

Joined: Mar 01, 2009
Posts: 1624
    
  13

Try checking the Oracle "2 day Java developer" tutorial: http://docs.oracle.com/cd/E17781_01/appdev.112/e18805/getconn.htm

It's aimed more at people using JDeveloper instead of Eclipse, but the JDBC connection details work teh same way.

You may also find it useful to download the free SQLDeveloper tool to use for building/exploring your database schema: http://www.oracle.com/technetwork/developer-tools/sql-developer/overview/index.html

That way you can look at your DB stuff even if your Java is in a mess.


No more Blub for me, thank you, Vicar.
 
Don't get me started about those stupid light bulbs.
 
subject: Getting started with Oracle 11g Express using Eclipse
 
Similar Threads
adding tables in to the oracle 11g database
Listener refused the connection with the following error: ORA-12505
login details for SYSTEM account in oracle 11g
Trouble Connectiing
InstallServlet error