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

The Power BI Data Visualization World Championships is back! Get ahead of the game and start preparing now! Learn more

Reply
SwathiGanesh
Frequent Visitor

Need total in the table and average in totals

I am working on one peculiar request,
We are using parameter in the table and we need totals in the rows and average in the totals.
Table is this format:

Partnername Partnertype Partnercountry Salary
A                   MVA              uk                1000
B                   DVP           us          2000
A                   MVA           us          3000
C                   MVN          uk          1000
A                  MVP          uk         1000

 

Parameter are : We have a slicer on the page
☑️Partnername
partnerTYPE
☑️partnercountry

The formula should consider all three columns[Partnername partnerTYPE partnercountry ]
I need result like this:

Partnername Partnercountry Salary
A             uk                     2000
Bus2000
Aus3000
Cuk1000
Total 2000

Tried this formula:
if(
Hasonevalue(parntername),
sum (salary),
average(salary))
But it's not working

1 ACCEPTED SOLUTION
ChrisMendoza
Resident Rockstar
Resident Rockstar

Try using ISINSCOPE like:

Measure ISINSCOPE = 
IF(
    ISINSCOPE(TableName[Partnername]),
    SUM(TableName[Salary]),
    AVERAGE(TableName[Salary])
)

 






Did I answer your question? Mark my post as a solution!
Did my answers help arrive at a solution? Give it a kudos by clicking the Thumbs Up!

Proud to be a Super User!



View solution in original post

2 REPLIES 2
ChrisMendoza
Resident Rockstar
Resident Rockstar

Try using ISINSCOPE like:

Measure ISINSCOPE = 
IF(
    ISINSCOPE(TableName[Partnername]),
    SUM(TableName[Salary]),
    AVERAGE(TableName[Salary])
)

 






Did I answer your question? Mark my post as a solution!
Did my answers help arrive at a solution? Give it a kudos by clicking the Thumbs Up!

Proud to be a Super User!



I am stuck and unable to find how to make “VAR SUMMERISE” to work, this variable should summerize the selected columns only. I am using this to find the denominator.
It works fine when all three columns are selected, but I need to summerize based on the selected column

Uniques =
var sumfc= sum (salary),
VAR SUMMERISE = SUMMARIZE(Partnername,Partnercountry, partnerTYPE, “Average”,sumfc)
return
IF(
OR(ISINSCOPE( 'Partnername),OR(ISINSCOPE( 'Partnercountry),ISINSCOPE(partnerTYPE))),
sum (salary),
DIVIDE(sumfc,COUNTROWS(SUMMERISE ))

)

Helpful resources

Announcements
November Power BI Update Carousel

Power BI Monthly Update - November 2025

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

Fabric Data Days Carousel

Fabric Data Days

Advance your Data & AI career with 50 days of live learning, contests, hands-on challenges, study groups & certifications and more!

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.

Top Solution Authors
Top Kudoed Authors