Register now to learn Fabric in free live sessions led by the best Microsoft experts. From Apr 16 to May 9, in English and Spanish.
Hello!
Hope someone can help me with this I have been trying to create a measure that adds the monthly result of another calculated measure which uses COUNTROWS but I'm not being able to get the desired result, my measures are defined as follows:
Reached Customers = COUNTROWS(FILTER(VALUES('Monthly'[Customers]),AND('Monthly'[PY Salesl]>1,[TY Sales]>1)))
Cumm Reached Customers =
VAR EarliestDate = CALCULATE(MIN(Calendar[Month]),ALLSELECTED())
RETURN CALCULATE([Reached Customers],FILTER(ALL(CCalendar[Month]),Calendar[Month]<= MAX(Calendar[Month]) && Calendar[Month]>= EarliestDate))
With this I get the following result:
Month | Reached Customers | Cumm Reached Customers | DESIRED Result |
01-Jan-17 | 22 | 22 | 22 |
01-Feb-17 | 23 | 34 | 56 |
01-Mar-17 | 32 | 47 | 103 |
01-Apr-17 | 27 | 51 | 154 |
01-May-17 | 32 | 55 | 209 |
01-Jun-17 | 30 | 59 | 268 |
As you see the Cumm Reached measure is only adding the different customers from each month, however what I need is for it to add month by month result (as shown in column DESIRED Result), I understand this is not working because my original measure "New Customers" is using COUNTROWS and VALUES thus filtering only distinct values, which is actually what I need for that measure, the problem comes when trying to add those values.
Please help!
Thanks!
Ale
Solved! Go to Solution.
Create two measures:
Distinct Customers = DISTINCTCOUNT('Sample'[Customer]) Cummulative Customers =
SUMX(
FILTER(ALL('Sample'[Date]), 'Sample'[Date] <= MAX('Sample'[Date])),
[Distinct Customers]
)
Drop date, and these two measures in a table and you have it.
Subscribe to the @PowerBIHowTo YT channel for an upcoming video on List and Record functions in Power Query!!
Learn Power BI and Fabric - subscribe to our YT channel - Click here: @PowerBIHowTo
If my solution proved useful, I'd be delighted to receive Kudos. When you put effort into asking a question, it's equally thoughtful to acknowledge and give Kudos to the individual who helped you solve the problem. It's a small gesture that shows appreciation and encouragement! ❤
Did I answer your question? Mark my post as a solution. Proud to be a Super User! Appreciate your Kudos 🙂
Feel free to email me with any of your BI needs.
Covering the world! 9:00-10:30 AM Sydney, 4:00-5:30 PM CET (Paris/Berlin), 7:00-8:30 PM Mexico City
Check out the April 2024 Power BI update to learn about new features.
User | Count |
---|---|
107 | |
100 | |
80 | |
63 | |
58 |
User | Count |
---|---|
148 | |
111 | |
94 | |
84 | |
67 |