Skip to Main Content

Oracle Database Discussions

Announcement

For appeals, questions and feedback about Oracle Forums, please email oracle-forums-moderators_us@oracle.com. Technical questions should be asked in the appropriate category. Thank you!

Using sysdate variable inside to_timestamp_tz() with timezone region

raulk89Nov 15 2017 — edited Nov 15 2017

Hi

Oracle 11.2.0.4.0

I have a slight problem, of which I would like to have a solution.

So how can I use SYSDATE variable for the following query (with the timezone region):

Ofcourse this works, if I write this date value explicitly:

select to_timestamp_tz('15.11.2017 08:26:00 Europe/Tallinn', 'dd.mm.yyyy hh24:mi:ss TZR') from dual;

My goal is to get something like this work (but this does not work like that):

select to_timestamp_tz(''||sysdate||' Europe/Tallinn', 'dd.mm.yyyy hh24:mi:ss TZR') from dual;

Any ideas..

Thanks in advance..

Regards

Raul

This post has been answered by AndrewSayer on Nov 15 2017
Jump to Answer
Comments
Locked Post
New comments cannot be posted to this locked post.
Post Details
Locked on Dec 13 2017
Added on Nov 15 2017
2 comments
328 views