Please start any new threads on our new site at https://forums.sqlteam.com. We've got lots of great SQL Server experts to answer whatever question you can come up with.

 All Forums
 SQL Server 2000 Forums
 SQL Server Development (2000)
 Stored procedure, Dynamic sorts, dynamic filters

Author  Topic 

AskSQLTeam
Ask SQLTeam Question

0 Posts

Posted - 2001-03-25 : 13:17:15
Keith writes "I have a table which has columns :

id	-	Identity
Name - Varchar
City - Varchar
State - Varchar
Country - Varchar
Zip - Varchar


I also have numerous tables similar to the above mentioned which have structures more or
less like this one above.

The number of rows for this particular table and other tables is expected to go to 100,00,00.

I need to write an ASP page which displays this info 10 records per page with 'Next' and 'Previous' buttons. The asp page needs to have functionality to sort (ASC & DESC) records on any column
displayed and filter records (I'm accepting the filter criteria on my page) on any column
displayed.

I need to have a common stored procedure in SQL Server 7.0 which does this (sorts ASC/DESC and filters too) without using 'temp' tables and that uses something like 'ROWCOUNT=10'.
Can you help with the SQL ??????????"
   

- Advertisement -