Earn a 50% discount on the DP-600 certification exam by completing the Fabric 30 Days to Learn It challenge.
Hello,
Need help with a DAX formula modification or a new DAX formula. User wants to see all the weekending dates that is available in the data set on a card visualization header on top of the report. when the report opens it is missing with the latest weekending date on the header even the data set has the latest weekending date. User has two options in the filter pane (circled in red color in the screen shot)
1. All (issues choosing all option ,missing the latest weekending date)
2. Is Latest (no issues, displays only the latest weekending data)
Please check the screen shots (Weekend Date) that displays weekending dates on the report and also check the screen shot that has the DAX formula that is used to display the dates.
Solved! Go to Solution.
Hello,
You can modify your formula a bit so that when ALL is selected from the slicer/filter pane, all dates are displayed. You can do something like this:
Measure =
VAR __All =
//use ALL function so all rows are included
CALCULATE (
CONCATENATEX ( VALUES ( Table[Date] ), Table[Date], "," ),
ALL ( Table )
)
VAR _Latest = <your expression/measure>
VAR __Selected =
SELECTEDVALUE ( Table[IsLatest] )
RETURN
//returns all when none is selected
SWITCH ( __Selected, "All", __All, "Latest", _Latest, __All )
Proud to be a Super User!
Hello,
You can modify your formula a bit so that when ALL is selected from the slicer/filter pane, all dates are displayed. You can do something like this:
Measure =
VAR __All =
//use ALL function so all rows are included
CALCULATE (
CONCATENATEX ( VALUES ( Table[Date] ), Table[Date], "," ),
ALL ( Table )
)
VAR _Latest = <your expression/measure>
VAR __Selected =
SELECTEDVALUE ( Table[IsLatest] )
RETURN
//returns all when none is selected
SWITCH ( __Selected, "All", __All, "Latest", _Latest, __All )
Proud to be a Super User!
It Works,Thank you..
You are doing an ALL over weekends in the second IF, but not in the first
It might need an ALL to counteract the results of the filter the user can put on the page.
I'm a personal Power Bi Trainer I learn something every time I answer a question. I blog at http://powerbithehardparts.com/
The Golden Rules for Power BI
Help when you know. Ask when you don't!
User | Count |
---|---|
103 | |
90 | |
78 | |
72 | |
68 |
User | Count |
---|---|
110 | |
96 | |
95 | |
74 | |
71 |