@"(select count(*) from 表 it WHERE 1=1 AND DelFlag='0' " + noorder + ") as Acount ";
string sql = @"select " + 总数+ ",* from " +
" ( SELECT ROW_NUMBER() OVER(ORDER BY 表1的字段 DESC) as NewTable,* FROM (select DISTINCT "+
" 查询的字段 from 表1 it "+
" WHERE 1=1 AND 条件1。。。。。" + 模糊查询条件+ " ) f ) as t where t.NewTable between " + start + " and ( " + start + " + " + limit + " ) ";
总数+行号+内容
int page = GetRequestParam<int>("page");
int rows = GetRequestParam<int>("rows");
int start = ((page - 1) * rows) + 1;
int limit = rows - 1;