File APIs for Java Developers
Manipulate DOC, XLS, PPT, PDF and many others from your application.
http://aspose.com/file-tools
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic

How to connect database in WSAD(websphere studio)

 
krussi rong
Ranch Hand
Posts: 62
  • 0
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Hi,
I use postgresql database,usually I just add
postgresql.jar file in classpath at VisualAge.
but in Studio,after I add a classpath variable of the postgresql.jar file, the
Class.forName("org.postgresql.Driver");
still can't found the Driver.
So anybody can help me about that?
thanks
Jenny
 
Cindy Glass
"The Hood"
Sheriff
Posts: 8521
  • 0
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Let's move this to the WebSphere forum.
 
Peter DeGregorio
Greenhorn
Posts: 10
Eclipse IDE Java Tomcat Server
  • 0
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
I am having a similar problem in WSAD but with Oracle. I'm trying to modify an application which uses (and finds) the PostgreSQL to use Oracle instead and am getting ClassNotFoundException at Class.forName("oracle.jdbc.driver.OracleDriver").newInstance();
I have added classes12.zip to the project's list of libraries, where postgresql.jar is also listed. If I set it up to run the PostregSQL driver it finds it but it does not find the Oracle driver.
 
Peter DeGregorio
Greenhorn
Posts: 10
Eclipse IDE Java Tomcat Server
  • 0
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
I got my program with the problem similar to yours (Oracle not PostgreSQL) to work in WSAD with both Websphere Test Environment and Tomcat by adding the JDBC driver jar to the class path of the server instance as an external jar. Hope this helps.
 
Baba Batsha
Ranch Hand
Posts: 94
  • 0
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
WTE class loader is not the same as WSAD WAS test environment. Make sure the JDBC drivers are in the right order for the class loader
 
I agree. Here's the link: http://aspose.com/file-tools
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic