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

The Power BI DataViz World Championships are on! With four chances to enter, you could win a spot in the LIVE Grand Finale in Las Vegas. Show off your skills.

Reply
Jake__789456
New Member

CALCULATE - Based on value in the data

Hello,

 

I am new to DAX and Power BI so please bare with me!

 

I am working with a report that contains many customer survey feedback responses for employees. Each employee is ranked on a score of 1 to 10. The scores are totalled up at the end of each quarter. I'd to create a column that calculates the total score for each employee per Q.

 

Here is an example that I created in excel. "Employee Total Per Q" is the extra column I would like to create

 

Jake__789456_0-1607650229770.png

 

I looked at the CALCULATE function but that seems to require a specific value to be inputted like "Q3". Is this too complicated for a new column? Is there a better way to do this?

 

Thanks!

1 ACCEPTED SOLUTION
wdx223_Daniel
Super User
Super User

in calculated column, use this code

=calculate(sum(table[survey score]),allexcept(table,table[employee],table[Q+Year]))

View solution in original post

2 REPLIES 2
Jake__789456
New Member

Thank you @wdx223_Daniel!

 

Your solution worked, I'm not sure I understand exactly why but thank you all the same! 😉

wdx223_Daniel
Super User
Super User

in calculated column, use this code

=calculate(sum(table[survey score]),allexcept(table,table[employee],table[Q+Year]))

Helpful resources

Announcements
Las Vegas 2025

Join us at the Microsoft Fabric Community Conference

March 31 - April 2, 2025, in Las Vegas, Nevada. Use code MSCUST for a $150 discount!

FebPBI_Carousel

Power BI Monthly Update - February 2025

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

Feb2025 NL Carousel

Fabric Community Update - February 2025

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