查询大数据表的效率对比:Linq to SQL、Entity Framework、企业(4)
{
IDataReader reader = selectPro();
if (reader != null)
{
int count = 0;
while (reader.Read())
{
count++;
//Response.Write(String.Format("{0}, {1}",reader[0], reader[1]));
}
Response.Write("<br>企业库存储过程 to DataReader 记录数:" + count);
reader.Close();
}
}
sw.Stop();
Response.Write("<br>企业库存储过程 to DataReader Milliseconds:<font color='#FF0000'>" + sw.ElapsedMilliseconds + "</font>");
Stopwatch sw6 = new Stopwatch();
sw6.Start();
DataSet ds=new DataSet();
for (int i = 0; i < repeatTimes; i++)
{
ds = selectProSet();
}
Response.Write("<br>企业库存储过程 to DataSet 记录数:" + ds.Tables[0].Rows.Count);
sw6.Stop();
相关新闻>>
- 发表评论
-
- 最新评论 更多>>