The ultimate Fabric, Power BI, SQL, and AI community-led learning event. Save €200 with code FABCOMM.
Get registeredEnhance your career with this limited time 50% discount on Fabric and Power BI exams. Ends August 31st. Request your voucher.
Dear Support Team,
I really need your help to solve my requirement. Thank you so much in advance. I have searched everywhere but not able to solve it.
My data source is as follows. Only one table, loaded from an excel (see below image).
I have to create 3 visuals (shown below) from the above data table.
Below is the complete report, I would like to implement.
Hey @Anonymous ,
this is not as simple as it may seem, this is because of the following.
DAX does not provide any means to determine the source of the filtering happening to table. This means if there are to slicers with the same input, it may be possible to make the slicer act as they are independent by adjusting the interaction settings.
But it's not possible to determine what date slicer has been used to filter the the table that contains the column, that is "feeding the slicer".
One question, that is not answered, what happens if more than 2 dates are uses?
I would write my measure like this. Assuming that VALUES(...[Date]) just contains 2 dates, I would use MAXX(VALUES(...) , '...'[date]) to determine one date and MINX to determine the 2nd date, and store these dates to 2 variables.
Then I would use these variables to calculate 2 other varialbles like so:
var value1 = CALCULATE(SUM('...'[Amount] , '...'[Date] = maxxdate)
var value2 = CALCULATE(SUM('...'[Amount] , '...'[Date] = minxdate)
The final result is than just the difference between value1 and value2.
I guess it's possible, that the 3rd visual will show a result that you might not expect.
Hopefully this provides you with some ideas.
Regards,
Tom
Hi Tom - well your solution was helpful for me but how to implement the same when the report is to be quarterly ?
Hi @TomMartens ,
Thank you for sharing your idea. However, It didn't help me to achieve the complete solution that I was looking for but using your idea, I am able to solve it differently and implement something similar. Here is how I did it.
User | Count |
---|---|
11 | |
8 | |
6 | |
6 | |
6 |
User | Count |
---|---|
24 | |
14 | |
13 | |
9 | |
8 |