Check your eligibility for this 50% exam voucher offer and join us for free live learning sessions to get prepared for Exam DP-700.
Get StartedDon't miss out! 2025 Microsoft Fabric Community Conference, March 31 - April 2, Las Vegas, Nevada. Use code MSCUST for a $150 discount. Prices go up February 11th. Register now.
Hey everyone,
Is there a way to count rows or distinctcount the articles where difference <0 ? Difference is a measure, based on several other measures.
I only need one return with 3 as result. I do understand that I can't use a card visual, because you can't aggregate when you want to filter on a measure. But isn't there a workaround?
Solved! Go to Solution.
Hello there @Anonymous ! Not sure if this is what you need but:
Measure =
CALCULATE(
COUNTROWS(
FILTER(
SUMMARIZE(
'Articles',
'Articles'[Aggregation_criteria],
"Diff", [Difference]
),
[Difference] < 0
)
)
)
Hope this answer solves your problem!
If you need any additional help please @ me in your reply.
If my reply provided you with a solution, please consider marking it as a solution ✔️ or giving it a kudoe 👍
Thanks!
You can also check out my LinkedIn!
Best regards,
Gonçalo Geraldes
Thank you guys! @goncalogeraldes , your suggestion worked perfectly, so I will be using that measure
You can use FILTER with a measure. As it is an iterator it will perform the check for each row of the given table, e.g.
Num < 0 = COUNTROWS( FILTER('Table', [Difference] < 0) )
and you should be able to use that on a card visual as well.
Hello there @Anonymous ! Not sure if this is what you need but:
Measure =
CALCULATE(
COUNTROWS(
FILTER(
SUMMARIZE(
'Articles',
'Articles'[Aggregation_criteria],
"Diff", [Difference]
),
[Difference] < 0
)
)
)
Hope this answer solves your problem!
If you need any additional help please @ me in your reply.
If my reply provided you with a solution, please consider marking it as a solution ✔️ or giving it a kudoe 👍
Thanks!
You can also check out my LinkedIn!
Best regards,
Gonçalo Geraldes
Let's assume there row filter context is from the column Table[Field] and the measure is [difference]
You can try:
Count Field =
COUNTX (
CALCULATETABLE ( VALUES ( Table[Filed] ), FILTER ( Table, [Difference] < 0 ) ),
Table[Field]
)
It should work in a card visual
Proud to be a Super User!
Paul on Linkedin.
March 31 - April 2, 2025, in Las Vegas, Nevada. Use code MSCUST for a $150 discount! Prices go up Feb. 11th.
Check out the January 2025 Power BI update to learn about new features in Reporting, Modeling, and Data Connectivity.
User | Count |
---|---|
144 | |
75 | |
64 | |
52 | |
47 |
User | Count |
---|---|
219 | |
89 | |
76 | |
67 | |
60 |