Skip to main content
cancel
Showing results for 
Search instead for 
Did you mean: 

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.

Reply
CloudMonkey
Post Prodigy
Post Prodigy

Equivalent of countifs in DAX using related fields

Hello

 

I need to find the number of sales in the last month for each combination of region and brand name (the reason being that I receive some KPI's by brand rather than by branch, but some brands spread accross several regions so I need to find which region each brand is most active in). Please can you tell me how to populate the column "Sales Volume For Brand And Region Combination" in table "Branches"? (I've hard coded the 4, 4, 2, 1 data for this mockup).

 

I basically need to do a countifs function from table "Branches" into table "Sales" that returns the number of sales for a given brand, region and fiscal period. Please can you tell me the best way to achieve this as a calculated column (not calculated measure)?

 

Many thanks for your help,

 

CM

 

Screenshot 1 - branches.JPGScreenshot 2 - Sales.JPGScreenshot 3 - Parameters.JPGScreenshot 4 - Dates.JPG

2 REPLIES 2
v-yulgu-msft
Microsoft Employee
Microsoft Employee

Hi @CloudMonkey,


 

 


Please can you tell me how to populate the column "Sales Volume For Brand And Region Combination" in table "Branches"? (I've hard coded the 4, 4, 2, 1 data for this mockup).

I cannot understand how to get the values "4, 4, 2, 1" for the new column. Please provide more description.

 


I basically need to do a countifs function from table "Branches" into table "Sales" that returns the number of sales for a given brand, region and fiscal period. 

 


What is your desired result? Could you illustrate requirment with examples? By the way, you said "returns the number of sales for a given brand, region and fiscal period", however, I didn't see brand, region and fiscal period in 'Sales' table.

 

Regards,

Yuliana Gu

Community Support Team _ Yuliana Gu
If this post helps, then please consider Accept it as the solution to help the other members find it more quickly.
CloudMonkey
Post Prodigy
Post Prodigy

Hi - not sure if this is impossible or if I haven't explained the problem clearly?

Helpful resources

Announcements
October Power BI Update Carousel

Power BI Monthly Update - October 2025

Check out the October 2025 Power BI update to learn about new features.

FabCon Atlanta 2026 carousel

FabCon Atlanta 2026

Join us at FabCon Atlanta, March 16-20, for the ultimate Fabric, Power BI, AI and SQL community-led event. Save $200 with code FABCOMM.