File APIs for Java Developers
Manipulate DOC, XLS, PPT, PDF and many others from your application.
http://aspose.com/file-tools
The moose likes Struts and the fly likes How to retrieve the data from the database table and display it on a jsp using struts Big Moose Saloon
  Search | Java FAQ | Recent Topics | Flagged Topics | Hot Topics | Zero Replies
Register / Login
JavaRanch » Java Forums » Frameworks » Struts
Bookmark "How to retrieve the data from the database table and display it on a jsp using struts" Watch "How to retrieve the data from the database table and display it on a jsp using struts" New topic
Author

How to retrieve the data from the database table and display it on a jsp using struts

Vidya Gupta
Ranch Hand

Joined: Mar 18, 2012
Posts: 96
Hi,

I am new to struts. I want to display all the details from a table on a jsp to user. Please help in doing these.

thanks in advance,
Lucky

Logindao.java
------------------

After getting the data from the above Logindao.java i want to forward data to my Action class i.e LoginActionClass.java.

LoginActionClass.java
----------------
Prabhakar Reddy Bokka
Ranch Hand

Joined: Jul 26, 2005
Posts: 189

Set the retrieved values into a bean, and put the been into session.
Now you can access the bean in JSP and display the values on the screen.


SCJP 5, SCWCD 5
Vidya Gupta
Ranch Hand

Joined: Mar 18, 2012
Posts: 96

first i want to know whether the code in Logindao.java class is correct or not to retrieve the data. If it is correct i want to return that result set in the form of list to my action class and from my action class to jsp. please help me..
tyte kyat
Ranch Hand

Joined: May 17, 2011
Posts: 40
http://www.vaannila.com/struts-2/struts-2-example/struts-2-hibernate-integration-1.html

This is a good start mate
Vidya Gupta
Ranch Hand

Joined: Mar 18, 2012
Posts: 96

please suggest me in doing this..
 
I agree. Here's the link: http://aspose.com/file-tools
 
subject: How to retrieve the data from the database table and display it on a jsp using struts
 
Similar Threads
Display each results from database in their own row
jsp not showing result in table form
accessing values from servlets to jsp
fow to forward to an action from jsp ?
How to retriew Data from Java Bean