Win a copy of Micro Frontends in Action this week in the Server-Side JavaScript and NodeJS forum!
  • Post Reply 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 all forums
this forum made possible by our volunteer staff, including ...
Marshals:
  • Campbell Ritchie
  • Liutauras Vilda
  • Paul Clapham
  • Bear Bibeault
  • Jeanne Boyarsky
Sheriffs:
  • Ron McLeod
  • Tim Cooke
  • Devaka Cooray
Saloon Keepers:
  • Tim Moores
  • Tim Holloway
  • Jj Roberts
  • Stephan van Hulst
  • Carey Brown
Bartenders:
  • salvin francis
  • Scott Selikoff
  • fred rosenberger

How to do database pagination using JSTL tags

 
Greenhorn
Posts: 13
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
I need to do Pagination from databse perspective. I am using Spring Framework with Jstl tags in the view.

Can any one suggest how to do that. I am using normal DAO class for JDBC connectivity so i dont want Hibernet or JSF to be used.

I need the solution as soon as possible
 
Ranch Hand
Posts: 884
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Depending on the database that you're doing, the method may differ. If you're using Oracle, you could go to Ask Tom and query on pagination. You would find what you need.

As for the custom tags, you could do a search at sourceforge.

 
Ranch Hand
Posts: 156
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Here goews the code.......



Now the database itteration where you wana apply pagination :



This logic will generate page numbers in the bottom.




I hope this will be usefull.
 
Pooja Chetty
Greenhorn
Posts: 13
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Thanks for the reply sachin,

The problem is i am giving the query in the JSP. I am giving in the DAOImpl Class. In that how should i customise the code given by you.

Pooja
 
With a little knowledge, a cast iron skillet is non-stick and lasts a lifetime.
reply
    Bookmark Topic Watch Topic
  • New Topic