select top 10*(pageno-1)
这里有没有错啊?pageno是传递的参数还是表中的字段名?从你的sql看,应该是在做新闻列表的分页,如果我没猜错,pageno是传递的参数,那应该这样写:
String sql="select top 10 * from jinrong.dbo.news where newsid not in ( select newsid from jinrong.dbo.specialcertain where specialid="+specialid+" ) and newsid not in ( select top " + 10*(pageno-1) + " newsid from jinrong.dbo.news where newsid not in ( select newsid from jinrong.dbo.specialcertain where specialid="+specialid+" ) )";