Managing Datasource in struts Application



Share on Google+Share on Google+

sudarshan kumar
Managing Datasource in struts Application
0 Answer(s)      4 years and 11 months ago
Posted in : Struts

Hi i need to know how to do set up of Oracle data base with struts using Data source.I have defined datasource in struts-config.xml as

        <data-source type="oracle.jdbc.pool.OracleConnectionPoolDataSource">
            <set-property property="URL" 
            <set-property property="user" value="SCOTT"/>
            <set-property  property="password" value="TIGER"/>

Then in my action class i am retrieving as

public ActionForward execute(
            ActionMapping mapping,
            ActionForm form,
            HttpServletRequest request,
            HttpServletResponse response) throws Exception {
        System.out.println("In Action of accept");
        String agregno = request.getParameter("agregno");
        boolean valid = Validation.acceptAgent(agregno, getDataSource(request));
        System.out.println("After val");
        if (valid) {
            return mapping.findForward("success");
        return mapping.findForward("fail");


I am getting error like getDatasource method does not exist.

View Answers

Related Tutorials/Questions & Answers:
Managing Datasource in struts Application
Managing Datasource in struts Application  Hi i need to know how to do set up of Oracle data base with struts using Data source.I have defined datasource in struts-config.xml as data-sources> <data-source type
datasource in jsp using struts
datasource in jsp using struts  how to get the datasource object in jsp.datasource is configured in struts-config.xml
configure Datasource in enterprise application - EJB
configure Datasource in enterprise application  I wanted to know that how can configure the DataSource in the Enterprise Application.Thanks Rohit Chauhan  which type of IDE u r using???If NetBeans ..Then i have
struts application
struts application  hi, how to retrive data from databse in struts application aand send the retrived data to corresponding form
Configuring Struts DataSource Manager on Tomcat 5
Configuring Struts DataSource Manager on Tomcat 5... can configure Struts DataSource Manager on the Tomcat 5.5.9 server. We will use... DataSource Manager to use MySQL Database and use the connection provided by Struts
struts application - Struts
struts login application form code  Hi, As i'm new to struts can anyone send me the coding for developing a login form application which involves a database search like checking user name in database
struts application
struts application  hi, i can write a struts application in this first i can write enter data through form sidthen it will successfully saved into data base **but now i can apply to some validation to that form fileds
First Struts Application - Struts
First Struts Application  Hello, Hello, I have created a struts simple application by using struts 1.2.9 and Jboss 4.0.4. I am getting... for path /WEB -INF/struts-config.xml struts-config.xml and web.xml files
struts application
struts application  i want to display name on the browser throgh struts1.2 in java please give me snippet
Why Struts in web Application - Struts
Why Struts in web Application  Hi Friends, why struts introduced in to web application. Plz dont send any links . Need main reason for implementing struts. Thanks Prakash
Struts application not working in LINUX - Struts
Struts application not working in LINUX  Hi ALL, I have a struts... in LINUX prodution system. The application is not recoginsed the web server is Tomcat5. I tryed with a sample servlet on linux tomcat its also not working
Struts Console
Struts Console         The Struts Console is a FREE standalone Java Swing application for managing Struts-based applications. With the Struts Console you can
Struts application by using eclipse
Struts application by using eclipse  Can we develop struts application by using eclipse ? If no then please provide other development tools, if yes can you mail me the tutorial or provide the same in roseindia
login application - Struts
application using struts and database?  Hello, Here is good example of Login and User Registration Application using Struts Hibernate and Spring. In this tutorial you will learn 1. Develop application using Struts 2. Write
Struts 2 Application
Struts 2 Application Developing user registration application based on Struts 2 Framework This Struts 2 Application is a simple user registration application.... Let's start developing user registration application on Struts 2 framework
develop structs application - Struts
structs application in netbeans ide i need step by step process plz answer me  Hi friend, For more information,Examples and Tutorials on Struts visit to : Thanks
Ajax in struts application - Ajax
Ajax in struts application  I have a running application using struts and now i want to implement Ajax(for populating some search box) in it.The problem is that my jsp page is able to send the request to my Struts Action process
Ajax for Struts with Hibernate Application - Struts
Ajax for Struts with Hibernate Application  Hi All, I have developed a registration page with country and state drop downs. I want to use ajax for these drop downs with hibernate support. Kindly help for this , thanks
struts - application missing something?
struts - application missing something?   Hello I added a parameter... in the struts working and all is great till I close JBoss or the server gets shut down..., struts-config.xml are all updated. I didn't use anything new that hasn't already
SwitchAction Application in struts 1.3.10
SwitchAction Application in struts 1.3.10  Hi,I am working on struts 1.3.10 and I have developed my module using switchaction application...' module. and 'action=/switchpath' is the action path to link struts-config.xml name
struts hibernate integration application
Struts2 hibernate integration application. In this tutorial we are going to show how to Integrate Struts Hibernate and create an application. This struts... of the struts hibernate integration application example. Description
Struts development application - Framework
Struts development application  hi friends, I want a source... regarding for struts framework,and what is difference b/w validation.xml and validation.... Thanks
Changing from Struts 1.2 to Struts 2.0 in Application
Changing from Struts 1.2 to Struts 2.0 in Application  Hi All, We have a financial application which is running successfully on struts 1.2 and java... latest version of struts 2.0. I want to know following things 1.what
Intranet application - Struts
Intranet application  Sir,I am develping a Intranet web application for college which has its own ip address and etc.I dont know how to deploy an application into server,changes to be done inside application.I am using struts.plz
Struts2 blank application - Struts
Struts2 blank application  Hi I am new to struts2 and i am trying to run the strutsblank application by following the following Link; http... application) when i am trying to open the application by using the link http
jsperexception in struts application
jsperexception in struts application  Iam getting the following error repeatedly can u explain the solution for this? HTTP Status 500 - type Exception report message description The server encountered an internal error
How to integrate Struts and Hibernate in an application?
How to integrate Struts and Hibernate in an application?  Hi, I am aware of both Struts and Hibernate framework. So, let's know how to integrate...;This project is about integrating the hibernate and struts frameworks. Check
struts 2 Application starting error - Struts
struts 2 Application starting error  Hello Sir/Madam, Recently i... application which i have attached with name Struts2Application, but after deploying and starting the application the message was received like Message
DataSource in hibernate.
DataSource in hibernate.  What is DataSource in hibernate?   Generally, in spring hibernate integration or struts hibernate integration we... --> <bean id="dataSource" class
how to compile and run struts application - Struts
how to compile and run struts application  how to compile and run struts program(ex :actionform,actionclass) from command line or in editplus 3
configuring ready-made struts application - Struts
configuring ready-made struts application  I have a source of Struts... browser. The only information that I have was, the project is built on Struts... the step by step guide on how to configure Struts but to no avail. Can anyone