mfc+ado+list control 分页显示数据

1、select top %d * from test where (id not in (select top %d id from test order by id))

2、获取记录总数
open时第三个参数要设置为:adOpenStatic;然后m_pRecordSet->RecordCount就可获取查询记录数。否则RecordCount值一直会是-1;

你可能感兴趣的:(mfc+ado+list control 分页显示数据)