I have a variable of type TIME, I need to divide the time of this variable by 2.
My SQL code:
DECLARE @TEMPO AS TIME = '01:31:00'
SELECT (@TEMPO / 2 ) AS RESULT
--the result should be: 00:45:30
SQL Server however throws an error:
Operand type clash: time is incompatible with int
Every help is welcome!