Hi Guys,
I have to convert a time value represented by decimal to a hh:ss format. I have come up with the following... Is there an easy (elegant) way to do this?
select SUBSTR(TO_CHAR(time),0, (INSTR(TO_CHAR(time),'.')-1)) || ':' ||
TO_CHAR((TO_NUMBER(SUBSTR(TO_CHAR(time), (INSTR(TO_CHAR(time),'.')+1), LENGTH(time)))/100)*60)
from (select '6533.50' time from dual);
Thanks,
Napster