JSF is normally setup to render output in HTML. Excel files are not HTML, so you really need an alternate renderer for them, for example, a servlet that outputs information using the Apache poi library.
Pageable dataTables are not provided in basic JSF, but most extension tagsets have a pageable dataTable component.
Making the columns sortable on the client side is a bit more trouble. If you want static sorting, you can attach actions to the column headings so that clicking on a column heading will trigger creation of a new DataModel with the rows sorted by that column. You'll have to do the sorting yourself.
If you want dynamic/AJAX sorting, use an extension tagset such as JBoss RichFaces, which has an extendedDataTable component that supports dynamic sort-by-column as well as the ability to filter what's displayed and do various other useful things.
Bjoke: A "Bully Joke". A Statement or action made with malicious intent - unless challenged. At which point it magically transforms into "I was just funnin'" or "What's the matter, can't take a joke?"
All you have to remember is that the backing bean needs to live after the first request (since the table sends ajax calls to bean when it does paging and sorting) so it needs to be in View, Session or Application scope (or in some other long living scope).
our requirements are in sync... Bad news is I am bound to use rich faces so I can not make use of existing components in other custom taglibs nor I am ready for writing a custom component. This is just luring me to have bite of unreachable grapes.
That is a bad situation indeed.
One way to accomplish the export requirement is to just do it yourself with a servlet (or JSF action). And you can look at the source code of primefaces (or the tomahawk wiki page that was behind my link) for hints on how to do it.