Forum Discussion
Measure to filter multiple categories
Hi, I have a basic filtering question. Using the table below, if I want a measure that collects ages just between 20-23 which gives me the count of 5, what measure would that be, please?
| Customer_ID | Age |
| 1 | 16 |
| 2 | 17 |
| 3 | 18 |
| 4 | 20 |
| 5 | 20 |
| 6 | 21 |
| 7 | 22 |
| 8 | 23 |
| 9 | 24 |
| 10 | 25 |
RichOB , Create a measure using
CountOfAges = CALCULATE(
COUNT(your_table_name[Customer_ID]),
your_table_name[Age] >= 20,
your_table_name[Age] <= 23
)
3 Replies
- bhanu_gautamSuper User
RichOB , Create a measure using
CountOfAges = CALCULATE(
COUNT(your_table_name[Customer_ID]),
your_table_name[Age] >= 20,
your_table_name[Age] <= 23
) - ToddChittSuper User
My Count of 20 to 23 = CALCULATE ( COUNT ( [Customer_ID] , [Age] >= 20 && [Age] <= 23 )
- AnonymousNot applicable
Your solution is so great ToddChitt and bhanu_gautam
Hi, RichOB
I wish you all the best. Previously Super user have provided a solution to help you solve the problem. Since we haven't heard back from you yet, I'd like to confirm if you've successfully resolved this issue or if you need further help?
If yes, you are welcome to share your workaround and mark it as a solution so that other users can benefit as well. If you find a reply particularly helpful to you, you can also mark it as a solution.
If you still have any questions or need more support, please feel free to let us know. We are more than happy to continue to help you.
Thank you for your patience and look forward to hearing from you.Best Regards
Jianpeng Li