Power BI is turning 10! Tune in for a special live episode on July 24 with behind-the-scenes stories, product evolution highlights, and a sneak peek at what’s in store for the future.
Save the dateEnhance your career with this limited time 50% discount on Fabric and Power BI exams. Ends August 31st. Request your voucher.
Hi All,
Need help with DAX formula to calculate productive store days with below sample data
Meaning of productive store days: >=10 units billed (of any Fruit) to a store on a day.
For below data, productive days will be 4 (A on 1st May, B on 1st & 4th May, C on 2nd May)
Thanks in advance.
Store | Fruit | Date | Sales units |
A | Apple | 1st May | 4 |
A | Orange | 1st May | 2 |
A | Banana | 1st May | 6 |
A | Orange | 3rd May | 3 |
A | Banana | 3rd May | 5 |
B | Apple | 1st May | 12 |
B | Orange | 4th May | 10 |
B | Banana | 5th May | 5 |
C | Apple | 2nd May | 6 |
C | Banana | 2nd May | 4 |
C | Apple | 5th May | 8 |
C | Orange | 9th May | 3 |
C | Banana | 9th May | 3 |
Solved! Go to Solution.
Hi @hcvora
You can try below measure.
productive store days =
COUNTROWS(
FILTER(
SUMMARIZE('Table','Table'[Store],'Table'[Date],"Units",SUM('Table'[Sales units])),
[Units]>=10
)
)
Did I answer your question? If yes, pls mark my post as a solution and appreciate your Kudos !
Thank you~
Hi @hcvora
You can try below measure.
productive store days =
COUNTROWS(
FILTER(
SUMMARIZE('Table','Table'[Store],'Table'[Date],"Units",SUM('Table'[Sales units])),
[Units]>=10
)
)
Did I answer your question? If yes, pls mark my post as a solution and appreciate your Kudos !
Thank you~
This worked! Thanks a lot.
User | Count |
---|---|
25 | |
11 | |
8 | |
6 | |
6 |
User | Count |
---|---|
30 | |
13 | |
11 | |
9 | |
6 |