Torna al Thread

create table ORARI ( id int identity(1,1), ora varchar(10) ) insert into ORARI select ('01.50') insert into ORARI select ('17.20') insert into ORARI select ('3.30') select (sum(T.ore) + floor(sum(T.minute) / 60)) as ORE, (sum(T.minute) - (60 * floor(sum(T.minute) / 60))) AS MINUTI from ( select *, CAST(left(ora, charindex('.',ora)-1) as int) as ore, CAST(substring(ora, charindex('.',ora)+1,2) as int) as minute from orari ) T
Copyright © dotNetHell.it 2002-2025
Running on Windows Server 2008 R2 Standard, SQL Server 2012 & ASP.NET 3.5