Technical Article

UDF to convert Seconds to DDD:MM:MM:SS Format

This function takes a number of Seconds in BIGINT format and calculations and displays that in a DDD:HH:MM:SS format.I wrote this because I needed to work out the duration between two datetimes and required the result to be displayed in a Report (VARCHAR (12)) format from a Select statementTo Use:SELECT dbo.csp_SecondsToDaysHoursMinutesSeconds(DATEDIFF(SS, , ))  AS DurationFROM […]

2002-05-09

290 reads

Blogs

Daily Coping 31 Jan 2023

By

Today’s coping tip is to take a small step towards and important goal. One...

Tales From The Field Weekly Wrap Up for the Week of 01-23-2022

By

 Hello Dear Reader!  It's been a while since I had time to sit down...

CONCAT_WS Function Truncates Text

By

I was writing some dynamic SQL that generates some SQL statements to load my...

Read the latest Blogs

Forums

The Data Fabric – Future of Data Management

By Ajay Kumar

Comments posted to this topic are about the item The Data Fabric – Future...

The Rise of Vector Databases

By Steve Jones - SSC Editor

Comments posted to this topic are about the item The Rise of Vector Databases

Backup Permissions

By Steve Jones - SSC Editor

Comments posted to this topic are about the item Backup Permissions

Visit the forum

Ask SSC Logo Ask SSC

SQL Server Q&A from the SQLServerCentral community

Get answers