My query returns the two fields in the select line. I need to find the difference in HH:MI:SS between the two fields. I keep getting errors when I try DIFF or even TO_DATE. The format for each field is different and the field are in different tables. ALARM_GENERATION_DT is in the PHM_INTERACTION_PERS table and the CALL_START is in the PHM_OUTBOUND table.
The formats for each field are as follows:
ALARM_GENERATION_DT mm-dd-yyyy hh:mi:ss AM/PM
CALL_START yyyy-mm-dd hh24:mi:ss
My current query is:
SELECT p.alarm_generation_dt, o.call_start
FROM phm_interaction_pers p, phm_outbound o
WHERE p.otb_id = o.record_id
AND o.call_start like '2015-03%';