2007. 7. 4. 18:01
select t2 as from_T, t1 as to_T,
trunc(t*(24),0) as HH,
trunc(mod(t*(24*60) ,60),0) as mi,
round(mod(t*(24*60*60),60),0) as ss
from (
select to_date('20070704161251','yyyymmddhh24miss') - to_date('20070704145000','yyyymmddhh24miss') as t,
to_date('20070704161251','yyyymmddhh24miss') as t1, to_date('20070704145000','yyyymmddhh24miss') as t2
from dual
)
FROM_T TO_T HH MI SS
2007-07-04 오후 2:50:002007-07-04 오후 4:12:51 1 22 51
'ORACLE' 카테고리의 다른 글
trace파일 만들기 (0) | 2008.04.18 |
---|---|
OR Mapping (0) | 2007.09.12 |
MS-SQL 접속 삽질의 날!!! (0) | 2007.06.29 |
CORE DUMP 해결방법 (0) | 2007.03.06 |
Pro*C란 (11) | 2007.03.06 |