Calculate exact datetime difference [Resolved]

Posted by Jpchoudhari under Sql Server on 6/28/2011 | Points: 10 | Views : 6022 | Status : [Member] | Replies : 2
Hi,

How to calculate exact date time difference in sql

Ex.

set @StartPauseTime='2011-06-24 00:54:36.503'
set @EndPauseTime='2011-06-24 02:11:02.563'

Date diff is 1 hours, 16 minutes and 26 seconds.

Thanks and Regards,
Jaydeep Choudhari

Kind Regards,
Jay



Responses

Posted by: PandianS on: 6/28/2011 [Member] [MVP] Silver | Points: 50

Up
0
Down

Resolved
Hi

Please check the URL given below for the solution:
http://sqlserverbuddy.blogspot.com/2011/06/hour-minute-second-between-two-date.html

Cheers
www.sqlserverbuddy.blogspot.com

Cheers
www.SQLServerbuddy.blogspot.com
iLink Multitech Solutions

Jpchoudhari, if this helps please login to Mark As Answer. | Alert Moderator

Posted by: Susanthampy on: 6/28/2011 [Member] [MVP] Bronze | Points: 25

Login to post response