Win a copy of Escape Velocity: Better Metrics for Agile Teams this week in the Agile and Other Processes 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 Pie Elite all forums
this forum made possible by our volunteer staff, including ...
Marshals:
  • Campbell Ritchie
  • Liutauras Vilda
  • Tim Cooke
  • Paul Clapham
  • Jeanne Boyarsky
Sheriffs:
  • Ron McLeod
  • Frank Carver
  • Junilu Lacar
Saloon Keepers:
  • Stephan van Hulst
  • Tim Moores
  • Tim Holloway
  • Al Hobbs
  • Carey Brown
Bartenders:
  • Piet Souris
  • Frits Walraven
  • fred rosenberger

Pagination in JSF

 
Greenhorn
Posts: 7
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
Can some one tell me how to do pagination in JSF.Are ther in built components for doing pagination in JSF. If possible provide me with some sample codes too. Its really urgent. Please help me out. Thanks in advance!!!
 
Ranch Hand
Posts: 140
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
Howzit George,

I stand to be corrected, but I think dataTable has pagination built into it, using the rows attribute. Maybe you can look at how that works. Let me know if it helps.
 
Darryl Nortje
Ranch Hand
Posts: 140
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
looks like it can be used hand in hand with tomahawk's dataScoller.
 
Greenhorn
Posts: 21
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
you can also try trinidad tags for this:
<tr:table rows="3">
<tr:column>
<tr:outputText value="#{Bean.name}"
</tr:column>
</tr:table>

This will make the table display only 3 values at a time and the remaining values will be displayed only after clicking the 'next' link which is defaultly displayed.
 
Greenhorn
Posts: 5
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
Hi,

If you use database by Hibernate then use following methods for pagination

criteria=criteria.setFirstResult(first);
setMaxResults(max);

Hibernate supports pagination by above methods .

--Thiru N
 
Ranch Hand
Posts: 31
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
Hi,
i think we can go for rich:datascroller for pagination in jsf.
here is the url for reference
http://livedemo.exadel.com/richfaces-demo/richfaces/actionparam.jsf?c=actionparam
 
Greenhorn
Posts: 13
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
hi all,
Is it possible to create customised messages near the drop down?. i mean instead of 'Next 1' and 'Previous 1', we need some other message to be shown there.

TIA,
Yuvaraj.
 
Ranch Hand
Posts: 121
Mac Eclipse IDE Chrome
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
Darryl,

you can use extended datatabe provided by ibm-jsf to achieve pagination.
there are many combinations, you can use pagination with scrollbar, only scrollbar, only pagenation etc.
its a hx component looks like
 
Thank you my well lotioned goddess! Here, have my favorite tiny ad!
the value of filler advertising in 2021
https://coderanch.com/t/730886/filler-advertising
reply
    Bookmark Topic Watch Topic
  • New Topic