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="oracle.jdbc.pool.OracleConnectionPoolDataSource">
            <set-property property="URL" 
   value="jdbc:oracle:thin:@192.168.11.106:1521:server"/>
            <set-property property="user" value="SCOTT"/>
            <set-property  property="password" value="TIGER"/>
        </data-source>
    </data-sources>

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");
        System.out.println(agregno);
        boolean valid = Validation.acceptAgent(agregno, getDataSource(request));
        System.out.println("After val");
        System.out.println(valid);
        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
Advertisements
struts application
struts application  hi, how to retrive data from databse in struts application aand send the retrived data to corresponding form
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
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
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 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
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 : http://www.roseindia.net/struts/ Thanks
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
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
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
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 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.... http://www.roseindia.net/struts/address_struts_validator.shtml Thanks
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
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
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
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
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
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
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
Struts application two submit button
Struts application two submit button  Hai, i'm new in struts application development , My code is <%@ taglib uri="http://struts.apache.org/tags-html" prefix="html" %> <%@ taglib uri="http://struts.apache.org/tags
Struts 2 Login Application
Struts 2 Login Application       Developing Struts 2 Login Application In this section we are going to develop login application based on Struts 2 Framework. Our current login application
Struts 2.1.8 Showcase application
Struts 2.1.8 Showcase application       In this section we will explore Struts 2.1.8 show case application. We will use Tomcat to install and test the application. I am assuming
how to develope a struts application using hibernate?
how to develope a struts application using hibernate?  Hi Folks, I am very new to hibernate.I want to develope a login page in struts their username...://www.roseindia.net/struts/struts-hibernate/ http://www.roseindia.net/struts
Configuring Actions in Struts application
Configuring Actions in Struts Application To Configure an action in struts application, at first write a simple Action class such as SimpleAction.java... to map the above files into an application. Here SimpleAction.java is your
using struts1 and struts2 in one application - Struts
using struts1 and struts2 in one application  My Application is in Struts 1.0 and all further enhancements to the application must be struts 2.0. and in future we will migrate entire application to struts 2.0.Is it possible
Struts Tutorial: Struts 2 Tutorial for Web application development, Jakarta Struts Tutorial
Struts 2 Ajax Struts 2 Application... Login/Registration Application Struts Hibernate Integration Apache... Struts 2 Tutorials - Jakarta Struts Tutorial Learn Struts 2
Struts2 netbeans 6.5.1 application error - Struts
Struts2 netbeans 6.5.1 application error  i develop struts simple application in netbeans 6.5.1 but every time generate appache error Requested resources not available in so give me solution please any body
How to make a chat application using Struts 2 ?
How to make a chat application using Struts 2 ?  Hello, I'm working on my final year project. i've to add chat application in that. how it can be done? 'm using eclipse for that.... plzzz reply
managing the transactions
managing the transactions  HI i am using JSF and SEAM and Hibernate when i search the record in JSF page , it dispalys all the records regarding search filter its fine my question is i want to merge the selected record profile
Jakarta Struts & Advanced JSP Course
. Using persistent data in a Struts application with JDBC... Jakarta Struts & Advanced JSP Course       Jakarta Struts Training Course Objective
About Struts 2.2.1 Login application
.style1 { margin-left: 80px; } About Struts2.2.1 login application In the most common login application there is  login form which is takes... message to the returns ERROR. All the Actions used in application must
Building and Testing Struts Hibernate Plugin Application
Building and Testing Struts Hibernate Plugin Application... will build and test our Struts Hibernate Integration application. Compiling... application with hibernate using Hibernate Struts Plugin.ADS_TO_REPLACE_4 You can
Developing Simple Struts Tiles Application
Developing Simple Struts Tiles Application  ... will show you how to develop simple Struts Tiles Application. You will learn... to your Struts application: Add the Tiles Tag Library Descriptor (TLD) file
help to load information in init of application - Struts
that is in init of the application , please remember, i am using struts2 framework. In this application i am not using any user defined interceptor. So can u tell me in the whole struts2 application, where should i write the code
How to make Struts Hibernate and Spring Based Login/Registration Application?
How to make Struts Hibernate and Spring Based Login/Registration Application.../Registration Application. Thanks   Hibernate struts is perfect choice to make application. Check the tutorial Developing Struts Hibernate and Spring Based
Entire Code for j2ee Application with struts and hibernate - Development process
Entire Code for j2ee Application with struts and hibernate  Hi friends can you give me sample code for Entire j2ee web application with struts... the following link: http://www.roseindia.net/struts/struts-hibernate
Java Captcha in Struts 2 Application
Java Captcha in Struts 2 Application     ... a captcha Servlet and use in your Struts 2 application. Developing Struts 2 Captcha Application In this section we are going to develop Captcha Servlet
Need help to create Struts 2 MySQL based HRMS application.
Need help to create Struts 2 MySQL based HRMS application.   Hi Sir, I am doing my project based on Human Resource Management system using struts 2 framework. I am beginner for struts framework. I tried to follow many example
Struts 2 Hello World Application Example, Learn how to develop Hello World application in struts 2.
Struts 2 Hello World - Developing Hello World Application...; In this section we will develop Hello World application based on Struts 2 Framework. Our Struts 2 Hello World application is your first step towards

Ads