• Post Reply Bookmark Topic Watch Topic
  • New Topic

How to add ojdbc.jar to my classpath?  RSS feed

 
Ranch Hand
Posts: 622
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
I have written a simple jdbc application to insert a record in database.

Before compiling, i need to add ojdbc.jar to my classpath.

How to do that?


On doing this, C:\oracle\product\10.2.0\db_1\jdbc\lib\ojdbc14.jar, it shows an error dialgue box stating,

Failed to load Main-Class manifest attribute from C:\oracle\product\10.2.0\db_1\jdbc\lib\ojdbc14.jar

 
Ranch Hand
Posts: 246
Firefox Browser Oracle
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Place it under "lib" folder in WEB-INF folder (ojdbc14) if there is any other jar files also recompile it
 
Bartender
Posts: 4012
42
Chrome Fedora Hibernate
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator

Kunal Lakhani wrote:Before compiling...


Few things you should mention here.
1. How do you compile, using a build script or just from the direct "javac" command?
2. What kind of application is this, web/desktop etc...?
 
Consider Paul's rocket mass heater.
  • Post Reply Bookmark Topic Watch Topic
  • New Topic
Boost this thread!