PL/SQL (MOSC)

MOSC Banner

DATE to TIMESTAMP with TIMEZONE

edited Sep 19, 2019 5:08AM in PL/SQL (MOSC) 3 commentsAnswered

Hi Team,

How can we convert DATE to TIMESTAMP WITH TIMEZONE.

For Example I have  column data like  "23-MAY-19' but i need to convert this to '2019-05-23 00:00:00 UTC'

I tried below query

SELECT  TO_TIMESTAMP(TO_CHAR(COLUMN,'YYYY-MM-DD HH24:MI:SS'),'YYYY-MM-DD HH24:MI:SS') as COLUMN FROM TABLE

output im getting like '23-MAY-19 12.00.00.000000000 AM'

Data type should be in TIMESTAMP only

Could you please help with the query

Thanks

Arjun

Tagged:

Howdy, Stranger!

Log In

To view full details, sign in to My Oracle Support Community.

Register

Don't have a My Oracle Support Community account? Click here to get started.

Category Leaderboard

Top contributors this month

New to My Oracle Support Community? Visit our Welcome Center

MOSC Help Center