Join us at FabCon Atlanta from March 16 - 20, 2026, for the ultimate Fabric, Power BI, AI and SQL community-led event. Save $200 with code FABCOMM.
Register now!Get Fabric Certified for FREE during Fabric Data Days. Don't miss your chance! Request now
Hi, hope you can help me out.
I have 2 different measures, one that counts the rows from a table containing light objects, and another one that counts in a different table the heavy ones; so I want to show a visual card with the count of the light, heavy or the sum of both, depending on what's selected on the filter that comes from another table, this table has merged the light and the heavy ones with a column that indicates the type "light" or "heavy" and this is the one I want to use to use as a filter.
so far this are the measures I have and I have them in the table with the mixed data.
Light = CALCULATE(COUNTROWS(V_Light), FILTER(MixedData, MixedData[Type]))
Heavy = CALCULATE(COUNTROWS(V_heavy), FILTER(MixedData, MixedData[Type]))
Thanks in advance.
Solved! Go to Solution.
Hi @garridog ,
Here we can create a measure as below.
Measure = var _sele = SELECTEDVALUE('Table'[Type])
var light = COUNTROWS(V_Light)
var heavy = COUNTROWS(V_heavy)
return
IF(_sele = "light",light,IF(_sele= "heavy",heavy,light+heavy))
Then we can get the result based on the value in slicer.
For more details, please check the pbix as attached.
Regards,
Frank
Hi @garridog ,
Here we can create a measure as below.
Measure = var _sele = SELECTEDVALUE('Table'[Type])
var light = COUNTROWS(V_Light)
var heavy = COUNTROWS(V_heavy)
return
IF(_sele = "light",light,IF(_sele= "heavy",heavy,light+heavy))
Then we can get the result based on the value in slicer.
For more details, please check the pbix as attached.
Regards,
Frank
Check out the November 2025 Power BI update to learn about new features.
Advance your Data & AI career with 50 days of live learning, contests, hands-on challenges, study groups & certifications and more!