Still celebrating National IT Professionals Day with 3 months of free Premium Membership. Use Code ITDAY17

x
?
Solved

how to do paging in jsp

Posted on 2003-11-18
6
Medium Priority
?
582 Views
Last Modified: 2012-05-04
Hi experts,
  i am a new java/jsp developer .
I'd like to know ,how to do Paging using JSP .I am retrieving 1000 records from the database.
First I want to display 10 records per page,after that the next 10 records should be displayed ,like that the following records should be displayed,how i can do this without using taglib.

please inform me to my mail ID:  <edited for privacy reasons by CetusMOD>   if anyone know that.
If u help me to do this,I'll be verymuch grateful to you.
Advanced thankx for all who is going to help me.

with warm regards,
karthick.k.e
0
Comment
Question by:kekarthick
[X]
Welcome to Experts Exchange

Add your voice to the tech community where 5M+ people just like you are talking about what matters.

  • Help others & share knowledge
  • Earn cash & points
  • Learn & ask questions
6 Comments
 
LVL 15

Accepted Solution

by:
jimmack earned 100 total points
ID: 9770215
First, it is against the EE rules to send answers or comments to an e-mail address.  The discussion must take place on this site.

http://www.experts-exchange.com/help.jsp#hi99

To respond to the question, try this:

http://jsptags.com/tags/navigation/pager/index.jsp
0
 

Expert Comment

by:superman19
ID: 9770323
ha.. this is the most common question that java's developer will ask.

For my case, i tackle this using the hard way. I need to perform some logic in the SQL statement rather than .net way, just choose the Paging Properties.. ha..
0
 
LVL 6

Expert Comment

by:jarasa
ID: 9771628
Hi Karthick.

You should use a Rownum in your query and then just take the records 10 by 10 something like this:

select * from (select ROWNUM rn, table.* from table) b where rn between rn_Init and rn_End;

where rn_Init equals 1 and rn_End equals rn_Init + 10

From your JSP you should call the estatement each time with the last rn you get if you go forward and if you are going backwards the you should call the statemente with the firts (rn - 10).

Have Fun
Javier


0
 

Expert Comment

by:abhinavchaturvedi
ID: 10360001
Hi experts,
  i am a new java/jsp developer .
I'd like to know ,how to do Paging using JSP .I am retrieving 1000 records from the database.
First I want to display 10 records per page,after that the next 10 records should be displayed ,like that the following records should be displayed,how i can do this without using taglib.


Advanced thankx for all who is going to help me.

with warm regards,
aby
0

Featured Post

New feature and membership benefit!

New feature! Upgrade and increase expert visibility of your issues with Priority Questions.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

Whoever said that “a picture is worth one thousand words” observed a fact that can dramatically affect your marketing success. Most people tend to learn visually, so many publishers commonly acknowledge the effectiveness of visual learning by using…
Instead of error trapping or hard-coding for non-updateable fields when using QODBC, let VBA automatically disable them when forms open. This way, users can view but not change the data. Part 1 explained how to use schema tables to do this. Part 2 h…
Video by: ITPro.TV
In this episode Don builds upon the troubleshooting techniques by demonstrating how to properly monitor a vSphere deployment to detect problems before they occur. He begins the show using tools found within the vSphere suite as ends the show demonst…
In this brief tutorial Pawel from AdRem Software explains how you can quickly find out which services are running on your network, or what are the IP addresses of servers responsible for each service. Software used is freeware NetCrunch Tools (https…

722 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question