I'm trying to convert India tz to UTC tz. I'm bit skeptical with the output. Can someone please help me with the query if I'm doing something wrong?
SELECT TO_CHAR(CAST(SYS_EXTRACT_UTC(FROM_TZ(TO_TIMESTAMP(TO_DATE('30-SEP-1941 23:00:00', 'DD-MON-YYYY HH24:MI:SS')), 'Asia/Calcutta')) AS DATE), 'DD-MON-YYYY HH24:MI:SS' ) FROM DUAL;
30-SEP-1941 17:07:00
I think the offset is 5:30, but the output shows 17:07.
But when I try as below, I'm seeing expected output:
SELECT TO_CHAR(CAST(SYS_EXTRACT_UTC(FROM_TZ(TO_TIMESTAMP(TO_DATE('01-OCT-1941 01:00:00', 'DD-MON-YYYY HH24:MI:SS')), 'Asia/Calcutta')) AS DATE), 'DD-MON-YYYY HH24:MI:SS' ) FROM DUAL;
30-SEP-1941 18:30:00
Using Windows 7
Oracle Database 12c Enterprise Edition Release 12.1.0.1.0 - 64bit Production