Hi All,
I want to know the logic how to get the current week of the year (June 26th - July 2nd). I don't want week number but I wanted to dynamically display the current week data .
Thanks !
Hi!
SELECT TIMESTAMPADD( SQL_TSI_DAY , 1 , TIMESTAMPADD(SQL_TSI_DAY , DAYOFWEEK(CURRENT_DATE) * -1 , CURRENT_DATE ) ) , TIMESTAMPADD( SQL_TSI_DAY , 7 , TIMESTAMPADD(SQL_TSI_DAY , DAYOFWEEK(CURRENT_DATE) * -1 , CURRENT_DATE ) ) FROM [YOUR_SUBJECT_AREA]
Hi,
From subject area means ? What actually do i need to give here. I am planning to create a dynamic variable based on this SQL. Can I do that ?
It is saying TIMESTAMPADD invalid identifier
It was sql-query for OBI.
If you want make dynamic variable, you need use classic sql:
ALTER SESSION SET NLS_TERRITORY = AMERICA; SELECT TRUNC(SYSDATE) - TO_NUMBER(TO_CHAR(SYSDATE,'D')) , TRUNC(SYSDATE) - TO_NUMBER(TO_CHAR(SYSDATE,'D')) + 7 FROM DUAL;
This 'D'-element returns the number of the day of the week (1-7). The day of the week that is numbered 1 is specified implicitly by the initialization parameter NLS_TERRITORY.
The best solution, not to depend on regional settings - you need make table "Calendar", where on each date you can assign day number of week (and week number, and year, and a lot more)
After that, you can get dates using simple query, example
SELECT DATE FROM CALENDAR WHERE YEAR = 2016 AND WEEK_NUM = 24 AND DAY_OF_WEEK_NUM IN (1, 7)
I used the same but it is just giving only 2 days instead of the whole week
But with this filters will this change dynamically everytime ? because whenever the user logins they wanted to see current week and further data only
You have table "Calendar", good.
But the field CALENDAR_DAY_of_the_week filled not as you need
Now you need to fill in the fields of the table so that 26.06.2016 was the first day of week, 02.07.2016 was the seventh day of week (most likely need to use a new column)
This query is dinamical:
SELECT DATE FROM CALENDAR WHERE YEAR = EXTRACT (YEAR FROM SYSDATE) AND WEEK_NUM = TO_NUMBER(TO_CHAR(SYSDATE, 'WW')) AND DAY_OF_WEEK_NUM IN (1, 7)
Put the textual representation of the week in your calendar dimension for each day ... a well-formed calendar dim will serve you well time and time again.
You can use Connect By Level to display all the days within current week. you need to find the current week from your Day table in warehouse.
refer these:
List of days between two dates
https://asktom.oracle.com/pls/apex/f?p=100:11:0::::p11_question_id:14582643282111
Agenda Presentation: What's New in FDI 26.R3 Open Q & A: Ask your questions of implementation and product specialists Replays of past FDI CEAL Guidance Office Hours are available on Oracle VideoHub here. Fusion Data Intelligence - CEAL Guidance Office Hours The FDI Office Hours are hosted by CEAL solution architects who…
So when I click the apply button, it uses the value . Also. How do I stop the auto populate table when the report opens???? I am in OAC
Good day, please kindly assist. We are creating a graph to calculate the number of assets per milestones. However, the planners have only populated assets for only one milestone from the list of milestones the customer wants to track. Which gives an incorrect view as the project moves past different milestones that it has…
I scheduled the report in OTBI and the agent was run successfully. However, I do not receive the report after the run in my inbox. The addresses are properly recorded, and the report is in an excel format and saved as a pivot table in otbi. What can be the cause?
Anyone has any idea why the OAC documentation on custom viz is not available now? I was able to access till last week - https://docs.oracle.com/en/cloud/paas/analytics-cloud/acsdv/build-package-extension.html. Does this mean OAC doesnt support custom viz or custom workbook extensions?
I made a parameter with letter range values… put it into a dashboard filter. Then I created an expression filter to bind it to my last name column in the table with the image I uploaded here. I am getting the following error??? Invalid Expression. Validation of parameter values failed. A general error has occurred. Message…