Win a copy of Testing JavaScript Applications this week in the HTML Pages with CSS and JavaScript forum!
  • Post Reply Bookmark Topic Watch Topic
  • New Topic
programming forums Java Mobile Certification Databases Caching Books Engineering Micro Controllers OS Languages Paradigms IDEs Build Tools Frameworks Application Servers Open Source This Site Careers Other all forums
this forum made possible by our volunteer staff, including ...
Marshals:
  • Campbell Ritchie
  • Bear Bibeault
  • Ron McLeod
  • Jeanne Boyarsky
  • Paul Clapham
Sheriffs:
  • Tim Cooke
  • Liutauras Vilda
  • Junilu Lacar
Saloon Keepers:
  • Tim Moores
  • Stephan van Hulst
  • Tim Holloway
  • fred rosenberger
  • salvin francis
Bartenders:
  • Piet Souris
  • Frits Walraven
  • Carey Brown

JDBC with OAS

 
Ranch Hand
Posts: 34
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Hello guys i have a problem

with deploying J2ee application

the apllication is working fine in case using tomcat as a webserver

but in case using the oracle application server i can't connect to the database

althogh using the same Way to connect to database

do i need any extra configauration for OAS to connect to DB

i use

OAS 10.1.2

jdbc connection
and this is my connection class

String url ="jdbc:oracle:thin:@SSLWFSRV:1521:DEVDB";


Class.forName("oracle.jdbc.driver.OracleDriver");
conn=DriverManager.getConnection(url,"user","Password");


thanks and regards
 
Bartender
Posts: 2658
19
Netbeans IDE C++ Linux
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Please post the errors.

You are not using the application server's database pool. You're using straightforward jdbc. So it should not be a server configuration issue.
Two possible causes for the error are: the oracle jdbc driver is not in your application's classpath, or
the database service defined in your connection string is not reachable from your OAS server.
The errors will tell you more.

Regards, Jan
 
Essam AbdelAziz
Ranch Hand
Posts: 34
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
url ="jdbc:oracle:thin:@SSLWFSRV:1521:DEVDB";

Class.forName("oracle.jdbc.driver.OracleDriver");
conn=DriverManager.getConnection(url,"user","pass");



thanks
 
Jan Cumps
Bartender
Posts: 2658
19
Netbeans IDE C++ Linux
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
That is the code. Can you post the errors you get when running the code? They will maybe show us what's going wrong.

Regards, Jan
 
Consider Paul's rocket mass heater.
    Bookmark Topic Watch Topic
  • New Topic