Hi All, i have small doubt about a stored writing as a combination of paging,sorting and searching.
For example i have 2 tables like
users-user id,username,password,region id
regions-regionid,region name
I am trying the stored procedure for searching and sorting.But i did not understand the paging.
The stored proc having parameters like
colname,searchname,pageindex,pagesize.
Can any one help to solve this one?
Loading

Akkiraju IvaturiRank #473 · 5.3K reputationPosted Jan 19, 2013, 2:12 PM EST
http://consultingblogs.emc.com/rorystreet/archive/2008/01/29/Paging-filtering_2C00_searching-and-sorting-in-one-stored-procedure.aspx
AartiRank #2,383 · 594 reputationPosted Dec 11, 2013, 1:05 AM EST
Jignesh TrivediRank #16 · 50.3K reputationPosted Dec 11, 2013, 1:43 AM EST
Agree with Aarti, using ROW_NUMBER() function you can easily done paging.
here you must create dynamic query....
Please refer
http://www.codeguru.com/csharp/.net/net_data/article.php/c19611/Paging-in-SQL-Server-2005.htm
http://www.c-sharpcorner.com/UploadFile/6bb76f/searching-sorting-and-paging-using-sql-query/
hope this will help you.