Search
 
SCRIPT & CODE EXAMPLE
 
CODE EXAMPLE FOR SQL

how to convert number to hours and minutes in oracle sql

WITH c AS (SELECT 492 AS MINUTES FROM DUAL)
SELECT trim(to_char(trunc(MINUTES / 60), '09')) || ':' ||
       trim(to_char(trunc(mod(abs(MINUTES), 60)), '09')) AS HHMM
FROM c;																-- 08:12
 
PREVIOUS NEXT
Tagged: #convert #number #hours #minutes #oracle #sql
ADD COMMENT
Topic
Name
2+5 =