Categories
- All Categories
- 15 Oracle Analytics Sharing Center
- 16 Oracle Analytics Lounge
- 216 Oracle Analytics News
- 43 Oracle Analytics Videos
- 15.7K Oracle Analytics Forums
- 6.1K Oracle Analytics Idea Labs
- Oracle Analytics User Groups
- 79 Oracle Analytics Trainings
- 15 Oracle Analytics Data Visualizations Challenge
- Find Partners
- For Partners
Unable to extract current date from current_timestamp for the local timezone in OTBI

Hi,
I have a requirement to report current day sales value. I am trying to leverage CURRENT_TIMESTAMP function as it gives me my local time. But when I try to extract date value from the current_timestamp after 5pm PST, it reverts to the next day as it picks the UTC time. Is there a way for me to override that and get the date part of the current_timestamp without UTC? Please advice.
Best
Shifa
Answers
-
Try this Replace with Current_Date and try below Sample Code to fetch Date value
SELECT TO_CHAR(TO_DATE(substr('2023-11-01T00:00:00.000+00:00',1,INSTR('2023-11-01T00:00:00.000+00:00','T',1)-1),'YYYY-MM-DD'),'dd-mon-yyyy', 'NLS_DATE_LANGUAGE=ENGLISH') from dual
0