Nothing to do with the query, you have a problem applying the page parameters for the page
to the model
View the original post :
http://www.jboss.com/index.html?module=bb&op=viewtopic&p=4103811#...
Reply to the post :
http://www.jboss.com/index.html?module=bb&op=posting&mode=reply&a...