Getting different results from FROM_TZ(TO_TIMESTAMP(...), DBTIMEZONE) query
Oracle Database 12c Enterprise Edition Release 12.1.0.2.0 - 64bit Production
PL/SQL Release 12.1.0.2.0 - Production
"CORE 12.1.0.2.0 Production"
TNS for Linux: Version 12.1.0.2.0 - Production
NLSRTL Version 12.1.0.2.0 - Production
The following query gives me 3 different results depending where I run the query from:
SELECT FROM_TZ(TO_TIMESTAMP(TO_CHAR(SYSDATE,'YYYY-MM-DD HH24:MI:SS')
,'YYYY-MM-DD HH24:MI:SS')
,DBTIMEZONE) as StartDate
FROM dual;
Result 1: 08-DEC-05 12.00.00.000000000 AM -08:00 (SQL*Developer)
Result 2: 08-DEC-05 12.00.00.000000000 AM -06:00 (LOCALHOST testing)**
Result 3: 08-DEC-05 12.00.00.000000000 AM -00:00 (Development testing)
I believe Result 2 is the correct result. I need to know how to ensure whatever machine may be issuing the query, the result will be the same.