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 Pie Elite all forums
this forum made possible by our volunteer staff, including ...
Marshals:
  • Campbell Ritchie
  • Jeanne Boyarsky
  • Ron McLeod
  • Paul Clapham
  • Liutauras Vilda
Sheriffs:
  • paul wheaton
  • Rob Spoor
  • Devaka Cooray
Saloon Keepers:
  • Stephan van Hulst
  • Tim Holloway
  • Carey Brown
  • Frits Walraven
  • Tim Moores
Bartenders:
  • Mikalai Zaikin

Could not get the connection in struts database application

 
Ranch Hand
Posts: 79
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Report post to moderator
Hi,

I worked in a struts database application, which access the oracle database using commons datasource and I configured it in the struts-config.xml and set it in the resource reference to access from JNDI.I followed the java case sensistiveness and no typos.I specified the type of the datasource as org.apache.commons.dbcp.BasicDataSource with key "jdbc/testess", that was configured as JNDI name using resource reference utility in the Netbeans IDE. In the resource reference, I specified the type as javax.sql.DataSource. Should it be differ from the type attribute of the datasource element specified in the struts-config.xml ? But in the resource reference, there is no option for the type org.apache.commons.dbcp.BasicDataSource but only four option among them I chose javax.sql.DataSource. I have given the code here. Please provide your valuable help to solve the problem.

with best regards,
Ramesh K
 
author & internet detective
Posts: 41860
908
Eclipse IDE VI Editor Java
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Report post to moderator
Looks like you accidentally submitted before adding the code. Anyone reading this: see full post with code
 
    Bookmark Topic Watch Topic
  • New Topic