Please start any new threads on our new
site at https://forums.sqlteam.com. We've got lots of great SQL Server
experts to answer whatever question you can come up with.
Author |
Topic |
dim
Yak Posting Veteran
57 Posts |
Posted - 2010-07-20 : 10:51:34
|
Hi,I have a column which is of type varchar and represents datetime information. E.g. 2010-06-21 07:22:21 I have a requirement wherein I need to get only the minutes part out of the whole string like 07:22 should be 442 minutes as the output.I need a suggestion about the way to achieve this task.Thank You,Dp |
|
RickD
Slow But Sure Yak Herding Master
3608 Posts |
Posted - 2010-07-20 : 11:01:25
|
SELECT DATEDIFF(minute,DATEADD(dd,0,DATEDIFF(dd,0,'2010-06-21 07:22:21')),'2010-06-21 07:22:21') |
 |
|
madhivanan
Premature Yak Congratulator
22864 Posts |
|
|
|
|