You can separate the hours, mins and seconds using SUBSTR
, then SUM
it up and finally use NUMTODSINTERVAL
function to convert it into INTERVAL
type.
SELECT NUMTODSINTERVAL (SUM (total_secs), 'second')
FROM (SELECT SUBSTR (duration, 1, 2) * 3600
+ SUBSTR (duration, 4, 2) * 60
+ SUBSTR (duration, 7, 2) total_secs
FROM user_tab);
与恶龙缠斗过久,自身亦成为恶龙;凝视深渊过久,深渊将回以凝视…