I have 2 columns (TotalDuration/ BartecDuration) and i need to get the avg duration of both column.
So far i have this
Select CONVERT(VARCHAR(255), CAST(AVG(CAST(CAST(TotalDuration AS DATETIME) AS DECIMAL(10,5))) AS DATETIME), 108) as TotalDuration, CONVERT(VARCHAR(255), CAST(AVG(CAST(CAST(BartecDuration AS DATETIME) AS DECIMAL(10,5))) AS DATETIME), 108) as BartecDuration from WasteCollectionStats
But the problem is i am only get the HH:MM:ss, and i need the milliseconds too.
Any help would be greatly appreciated :)