If you want to sort you need to re-run the query that collected the data and add and orber by clause.... eg
Code:
select * from cases order by caseNumber
(of course don't use * specify your fields)
So you make the order by part of your sql statement dynamic and pass the field you want to order by in the querystring... something like...
Code:
<a href="caseResults.asp?orderby=caseNumber">Case Number</a>
and
Code:
strSql = "select * from cases"
orderBy = Request.QueryString("orderby")
if orderBy<>"" then strSql = strSql + "order by " orderBy
if you have a where clause included in the query you will need to make sure you have access to the data for this where clause as well.