Convert TIME to Seconds in MSSQL

 

Just put in the Time, and it will return the Seconds

DECLARE @Time Varchar(10)

SELECT DATEDIFF(second,0,cast(@Time as datetime))


Comments

Popular posts from this blog

JavaScript Regexp Regular Expression

Mvc Razor Load Partial view using javascript