Earn a 50% discount on the DP-600 certification exam by completing the Fabric 30 Days to Learn It challenge.
Hi,
How can i calculate next 30 days data in calendar. For example today's date is (12/14/2019)+29 days in calendar table with day name as a column and date and data inside the calendar visual week wise.
Thanks,
-Arul
Hi @Arul ,
you mean this?
Calendar =
SELECTCOLUMNS (
CALENDAR ( TODAY (); TODAY () + 29 );
"Date"; [Date];
"Day"; FORMAT ( [Date]; "dddd" );
"Week"; FORMAT ( [Date]; "yyyy ww" )
)
...this calendar includes pretty much everything.
https://www.sqlbi.com/articles/reference-date-table-in-dax-and-power-bi/
If I answered your question, please mark my post as solution, this will also help others.
Please give Kudos for support.
Try
Sales 30 Days = (
VAR _Cuur_start = Max('Compare Date'[Compare Date])
VAR _Curr_END = Max('Compare Date'[Compare Date])+29
return
calculate((sum(Sales[Sales Amount])),Sales[Sales Date] >= _Cuur_start && Sales[Sales Date] <= _Curr_END )
)
Hi @Arul
not sure how do you wanna store and visualize this but maybe try a simple calculated column like
Column = if(datediff(TODAY();'Calendar'[Date];DAY)<=29;TRUE();FALSE())
do not hesitate to give a kudo to useful posts and mark solutions as solution
Hi @az38 @mwegener @amitchandak
Is there any visual like calendar visual to show the data for the next 30 days irrespective of the month. In my case calendar visual will not fulfill the requirement.
Thanks,
-Arul
Hi @Arul ,
has your question been answered?
If I answered your question, please mark my post as solution, this will also help others.
Please give Kudos for support.
Hi @Arul ,
what kind of data do you want to display.
You could e.g. use a "clustered column chart". Put the date on the axis and filter it with a relative filter for the next 30 days.
If I answered your question, please mark my post as solution, this will also help others.
Please give Kudos for support.
User | Count |
---|---|
102 | |
91 | |
87 | |
79 | |
71 |
User | Count |
---|---|
113 | |
105 | |
101 | |
75 | |
64 |