Oracle Support Mathematical Subtraction - Operator by Data Data Type. You can directly put the following statement in the select clause:
to_char (s.last_upd β s.created, '999999D99β²)
Check EXAMPLE for more visibility.
If you need a conclusion in terms of hours, then below may help;
Select to_number(substr(numtodsinterval([END_TIME]-[START_TIME]),'day',2,9))*24 + to_number(substr(numtodsinterval([END_TIME]-[START_TIME],'day'),12,2)) ||':'||to_number(substr(numtodsinterval([END_TIME]-[START_TIME],'day'),15,2)) from [TABLE_NAME];
Nadeem_mk
source share