随笔-34  评论-0  文章-0  trackbacks-1

计算sql语句的执行时间

use kfc --数据库
declare @date1 datetime 
declare @date2 datetime 
select @date1=getdate() 
--测试语句 
select * from test where myname ='123'
select @date2=getdate()
--结果是毫秒数
select datediff(millisecond, @date1, @date2)
标签: sql, 执行时间
posted on 2011-08-27 19:19 小小池 阅读(17) 评论(0) 编辑 收藏
  设计重在构思。技术在变,思想永不过时。
昵称:小小池
园龄:6年9个月
粉丝:0
关注:0
<2011年8月>
31123456
78910111213
14151617181920
21222324252627
28293031123
45678910

搜索

 
 

常用链接

我的标签

随笔分类

随笔档案

ORM

积分与排名

  • 积分 - 24222
  • 排名 - 4343

最新评论

阅读排行榜

评论排行榜

推荐排行榜