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

Power BI is turning 10! Let’s celebrate together with dataviz contests, interactive sessions, and giveaways. Register now.

Reply
NJ81858
Helper IV
Helper IV

Measure in Power BI Report Builder

Hello,

 

I am transferring a report from Power BI to a paginated report and I have a measure in my Power BI report that I am not sure how to transfer it over to the paginated report in Power BI Report Builder. My measure in Power BI is:

 

% Yes = 

VAR _yes = CALCULATE(COUNT('Table'[Value]), FILTER('Table', [Group] = "Yes"))
VAR _total = COUNT('Table'[Value])
RETURN
DIVIDE(_yes, _total)

 

Any help is greatly appreciated, thank you in advance!

3 REPLIES 3
Shahfaisal
Solution Sage
Solution Sage

Try this:

 

=IIF(Fields!Group.Value = "Yes", Count(Fields!Value.Value), 0) / Count(Fields!Value.Value)

@Shahfaisal I have entered this as a formula but when I try and input that into my graph, it gives me the following error:

 

"The expression used for the calculated field 'Percent' includes an aggregate, RowNumber, RunningValue, Previous or lookup function. Aggregate, RowNumber, RunningValue, Previous and lookup functions cannot be used in calculated field expressions.
----------------------------
The definition of the report '' is invalid.
----------------------------
An error occurred during local report processing."

 

I am not sure where I am going wrong with my formula.

The expression should be used in a group row but it looks like you used it in a detail row.

See https://learn.microsoft.com/en-us/sql/reporting-services/lesson-6-adding-grouping-and-totals-reporti...

 

Helpful resources

Announcements
June 2025 Power BI Update Carousel

Power BI Monthly Update - June 2025

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

June 2025 community update carousel

Fabric Community Update - June 2025

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