Help ibatis pagination practice, thank you!

Category: Java EE
2009-09-23 11:35:06

Sponsored Links
Ibatis brother now learning technology, display data already, but the practice has been on the page did not understand the Internet to find case also harvested small, probably not many people now use ibatis it. So that they could help everyone, I hope there is understanding of the brothers help out, there are cases of source code better, thank you!

Sponsored Links

2009-09-23 11:38:38
Does nobody know?
2009-09-23 11:43:09
itself with a function:
List list = sqlMap.queryForList ("getProductList", null, data starts, end of data);
2009-09-23 11:54:18
Thank you pull topirol (I love learning)
2009-09-23 12:06:09
I wrote a method for flip obtained:
Note: This is based on the Spring framework to achieve!

public List paginate (String flag)
; PaginatedList paginatedList = this.getSqlMapClientTemplate (). queryForPaginatedList ("getUserByQueryString", null, 5);

if ("privious". equals (flag))
paginatedList.previousPage ();
else if ("next". equals (flag))
paginatedList.nextPage ();

return paginatedList;

in JSP, the following call:
<button onclick="location.href =''"> Privious page </button>
; <button onclick = "location.href = ' action = paginate & flag = next '"> Next page </button>

If in doubt, welcome to the next contact:
Email: [email protected]
QQ: 475987473
Domain and server ip had changed since 8/23/2013. Suspend the user registration and posts for program maintenance.