Earn a 50% discount on the DP-600 certification exam by completing the Fabric 30 Days to Learn It challenge.
Hi All,
I created two measures in the attached sheet which is as below for an Inflow/outflow report:
Inflow =
VAR d =
MAX ( 'Date'[YearMonthShort] )
RETURN
CALCULATE(DISTINCTCOUNT('Page 1'[Number]), 'Page 1'[MonthYearOpened]=d)
Outflow =
VAR d =
MAX ( 'Date'[YearMonthShort] )
RETURN
CALCULATE(DISTINCTCOUNT('Page 1'[Number]), 'Page 1'[MonthYearClosed]=d)
Where I have used the below formulae to format both the Opened and Closed date to MMMM YYYY format as it facilitated me to create an Inflow/Outflow based on monthly basis.
MonthYearClosed = FORMAT([Closed],"YYYY mmmm")
MonthYearOpened = FORMAT([Opened],"YYYY mmmm")
Everything is working as it should until this point where I wanted to create a line which should contain the distinct count of ticket numbers between Inflow & Outflow on top of the attached chart where I am stuck now (Line and Clustered Column Chart).
Please help!
Link to PBIX & Data file: https://1drv.ms/u/s!An1nJ6oXziI6hKJYHWwoKZHUW8QnOg?e=CrIyAh
Solved! Go to Solution.
@Anonymous Sample test data will always be helpful.. but based on your description, hope I've understood correctly... Add a new measure to have count of both Inflow and Outflow as below. Let me know how it goes....
Total = CALCULATE(DISTINCTCOUNT('Page 1'[Number]), FILTER(ALL('Page 1'),[MonthYearClosed]=d OR [MonthYearOpened]=d))
Proud to be a PBI Community Champion
@Anonymous Sample test data will always be helpful.. but based on your description, hope I've understood correctly... Add a new measure to have count of both Inflow and Outflow as below. Let me know how it goes....
Total = CALCULATE(DISTINCTCOUNT('Page 1'[Number]), FILTER(ALL('Page 1'),[MonthYearClosed]=d OR [MonthYearOpened]=d))
Proud to be a PBI Community Champion
It worked like awesome!
Thanks a ton...
However I am keeping it open before accepting it as a solution a I would like other inputs as well to gain some potential knowledge out of this.
Below is the final formula that made it work:
Can you give a sample of your expected solution/result?
I did not follow your explanations.
Cheers!
Can you share sample data and image of your chart?
User | Count |
---|---|
103 | |
88 | |
78 | |
71 | |
69 |
User | Count |
---|---|
113 | |
99 | |
97 | |
72 | |
68 |