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
Data looks like this:
Column A Column B
asdf no
adsf yes
adsf no
czcz yes
czcz yes
I want to count the "yes" values and i want to add a calculated column (Column C) that looks like this below where the # of yes's for a given value in column A is shown for all of those values if it repeats:
Column A Column C
asdf 1
adsf 1
adsf 1
czcz 2
czcz 2
Thanks in advance...
Solved! Go to Solution.
Please try this column expression, replacing Table with your actual table name.
Yes Count =
CALCULATE (
COUNT ( Table[ColumnA] ),
ALLEXCEPT (
Table,
Table[ColumnA]
),
Table[ColumnB] = "yes"
)
Regards,
Pat
To learn more about Power BI, follow me on Twitter or subscribe on YouTube.
Hi,
Try his calculated column formula
=CALCULATE(CALCULATE(COUNTROWS(Data),Data[Reply]="yes"),FILTER(Data,Data[Text]=EARLIER(Data[Text])))
Hope this helps.
Hi,
Try his calculated column formula
=CALCULATE(CALCULATE(COUNTROWS(Data),Data[Reply]="yes"),FILTER(Data,Data[Text]=EARLIER(Data[Text])))
Hope this helps.
Please try this column expression, replacing Table with your actual table name.
Yes Count =
CALCULATE (
COUNT ( Table[ColumnA] ),
ALLEXCEPT (
Table,
Table[ColumnA]
),
Table[ColumnB] = "yes"
)
Regards,
Pat
To learn more about Power BI, follow me on Twitter or subscribe on YouTube.
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!