Earn a 50% discount on the DP-600 certification exam by completing the Fabric 30 Days to Learn It challenge.
Hi ,
I’m developing a report in powerbi I have two slicers one slicer with Year& Month combined in Date hierarchy and another slicer with type as YTD & selected month & trailing12months I have to calculate for the below listed in DAX could you please anyone help me
I'm New to DAX finding difficult to calculate the below
Data model:
Date table connected with 1 side to many side of sales table
Disconnected Type slicer table
Case 1: IF Year month slicer & type slicer if user selected the month then it should show the running total of sales amount till max of selected month
Case 2: IF Year month slicer & type slicer is blank then it should show the running total of sales amount from latest year from Jan to max month
Case 3: IF Year month slicer & type slicer is blank then it should show the month of sales amount from latest year Jan to max month
Case 4: IF Year month slicer & type slicer whichever month the user selected then it should show that month sales amount only
Case 5: IF Year month slicer & type slicer is blank then it should show the sales amount from latest year from Jan to max month
Case 6: IF Year month slicer & type slicer is blank then it should show the sales amount of last 12 months from selected month
urgent request can anyone please help me
Thank you.
I have taken a copy of Date table added in the model as previous Date and set the relationship as many side of Date table to one side of previousdate table and computed the below measure however it is not working could you please provide the email ID of yours so that i can send you the actual PBIX file
@NT92 you can upload your pbix to OneDrive or Google Drive and post a link for myself or another user to download. I'll take a look at it in the morning.
Hi @NT92
What you can do is create a measure that works like this...
SWITCH(
SELECTEDVALUE(DisconnectedSlicerTable[FieldName]),
"YTD", [Measure for YTD],
"Selected Month", [Measure for Selected Month]
--Repeat as necessary
)
Hope this helps!
User | Count |
---|---|
57 | |
21 | |
19 | |
18 | |
16 |
User | Count |
---|---|
85 | |
80 | |
52 | |
37 | |
22 |