File APIs for Java Developers
Manipulate DOC, XLS, PPT, PDF and many others from your application.
The moose likes JDBC and Relational Databases and the fly likes Configuring an IDE w/2 JDBC Drivers Big Moose Saloon
  Search | Java FAQ | Recent Topics | Flagged Topics | Hot Topics | Zero Replies
Register / Login

Win a copy of Head First Android this week in the Android forum!
JavaRanch » Java Forums » Databases » JDBC and Relational Databases
Bookmark "Configuring an IDE w/2 JDBC Drivers" Watch "Configuring an IDE w/2 JDBC Drivers" New topic

Configuring an IDE w/2 JDBC Drivers

Dale DeMott
Ranch Hand

Joined: Nov 02, 2000
Posts: 515
I'm working w/Eclipse and currently have in my "RUN" config [under the argument tab] the following line.


This is great if I want to only run 1 database. I have 2 that I need to use. Does anyone know how I can cofigure my eclipse to accept 2 jdbc drivers for 2 databases?


By failing to prepare, you are preparing to fail.<br />Benjamin Franklin (1706 - 1790)
Scott Selikoff
Saloon Keeper

Joined: Oct 23, 2005
Posts: 3740

I believe the command line option you list is more of a convenience option than a requirement. You can leave it off altogether, add both jars to the classpath, and then in the code registrar which jdbc driver you want to use during runtime.

[OCA 8 Book] [Blog]
Paul Sturrock

Joined: Apr 14, 2004
Posts: 10336

That will work, assuming there is a driver for that url in your classpath.
[ January 18, 2007: Message edited by: Paul Sturrock ]

JavaRanch FAQ HowToAskQuestionsOnJavaRanch
Dale DeMott
Ranch Hand

Joined: Nov 02, 2000
Posts: 515
Here's what I'm trying...

Here's the method...

The problem is that the class that I'm registering does NOT extend the Driver class that the driver manager wants it cast to.

Any suggestions?...
subject: Configuring an IDE w/2 JDBC Drivers
It's not a secret anymore!