笔记131 计算日期差datediff

笔记131 计算日期差datediff

1 --计算日期差datediff
2 SELECT  DATEDIFF(day, '1999/07/19 00:00', '1999/07/23 23:59')
3   
4 SELECT  DATEDIFF(month, '1987/05/02', '1995/11/15')
5   
6 SELECT  DATEDIFF(day, '00:00', '23:59')
7   
8 SELECT  DATEDIFF(month, '1999/07/19', '1999/08/23')

 

posted @ 2013-08-03 22:53  桦仔  阅读(297)  评论(0编辑  收藏  举报