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

Enhance your career with this limited time 50% discount on Fabric and Power BI exams. Ends August 31st. Request your voucher.

Reply
Cyriackpazhe
Helper III
Helper III

expanded table

Calculate ( countrows( Regions), Sales)) . Here Regions is part of the expanded table of Sales. Can someone explain how the table "Sales" as calculate argument is used to evaluate the expression. The Regions[Regions] column part of the expanded "sales" table.

1 ACCEPTED SOLUTION
Anonymous
Not applicable

Hi ,

Based on the information, the countrows(Regions) function counts the number of rows in the Regions table. Because CALCULATE adjusts the filter context using the Sales table, only those Regions that are linked to the current set of rows in Sales are considered.

vjiewumsft_0-1739524428772.png

vjiewumsft_1-1739524435654.png

Using the DAX formula.

vjiewumsft_2-1739524461068.png

 

You can view the following documents to learn more information.

CALCULATE function (DAX) - DAX | Microsoft Learn

COUNTROWS function (DAX) - DAX | Microsoft Learn

 

Best Regards,

Wisdom Wu

If this post helps, then please consider Accept it as the solution to help the other members find it more quickly.

View solution in original post

2 REPLIES 2
Anonymous
Not applicable

Hi ,

Based on the information, the countrows(Regions) function counts the number of rows in the Regions table. Because CALCULATE adjusts the filter context using the Sales table, only those Regions that are linked to the current set of rows in Sales are considered.

vjiewumsft_0-1739524428772.png

vjiewumsft_1-1739524435654.png

Using the DAX formula.

vjiewumsft_2-1739524461068.png

 

You can view the following documents to learn more information.

CALCULATE function (DAX) - DAX | Microsoft Learn

COUNTROWS function (DAX) - DAX | Microsoft Learn

 

Best Regards,

Wisdom Wu

If this post helps, then please consider Accept it as the solution to help the other members find it more quickly.

some_bih
Super User
Super User

@Cyriackpazhe in Power BI with Star schema model, Sales table is fact table and via relationships other tables are expaned table of Sales, some of details on link.

 





Did I answer your question? Mark my post as a solution!

Proud to be a Super User!






Helpful resources

Announcements
July 2025 community update carousel

Fabric Community Update - July 2025

Find out what's new and trending in the Fabric community.

July PBI25 Carousel

Power BI Monthly Update - July 2025

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