Forum Discussion
How to overcome error "Function 'DATEADD' expects a contiguous selection..." with bi-dir date table
- 3 years ago
Thank you for your message NikhilChenna .
However, in my case, due to the narrow timeframe of dataset, currently I have data only for this year, and in every situation I want to compare two following quarters, so they are indeed contiguous.
And also, based on this logic this should break both quarter names and numeric calculations.In the meantime I found one, not very elegant tho, solution, which after initial testing seems working fine.
I have replaced the previously used measure for giving previous of the selected quarter:PreviousQrt =CALCULATE((fct_SendMessages[SelectedQrt]),DATEADD('Calendar'[Date], -1, QUARTER))And replaced with this measure:PreviousQrt_viaMax =CALCULATE(MAX('Calendar'[Quarter])) -1
As I have mentioned, not very elegant, but it seems it is doing the required job, so far all is good. I think we can close this thread.Thank you
Thank you for your message NikhilChenna .
However, in my case, due to the narrow timeframe of dataset, currently I have data only for this year, and in every situation I want to compare two following quarters, so they are indeed contiguous.
And also, based on this logic this should break both quarter names and numeric calculations.
In the meantime I found one, not very elegant tho, solution, which after initial testing seems working fine.
I have replaced the previously used measure for giving previous of the selected quarter:
As I have mentioned, not very elegant, but it seems it is doing the required job, so far all is good. I think we can close this thread.
Hi Draginko ,
As the you said it seems it is doing the required job, so far all is good. I think we can close this thread.
Appreciate with a Kudos!! (Click the Thumbs Up Button)
Did I answer your question? Mark my post as a solution!