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

The ultimate Microsoft Fabric, Power BI, Azure AI & SQL learning event! Join us in Las Vegas from March 26-28, 2024. Use code MSCUST for a $100 discount. Register Now

Reply
Anonymous
Not applicable

Calculating customer satisfaction scores

Hi

 

This is my first post but i have been using Power BI for a few months now. I'm struggling with getting a percentage score from DAX and need some help. I have two customer satisfaction surveys, one where 1= very good 5= very bad and another where 1=very bad and 5=very good. The calculation is the sum of all the responses / count of the number of responses.

 

I have three columns for each survey (1 header for each question). And i have the results in the rows below with another column giving me the name of the employee the survey was for

 

I've tried playing about with the below formula but it doesn't give me an individual score

 

sat score = Divide(countx('Survey,'Survey'[Q1]+'Survey'[Q2]+'Survey'[Q3]),sumx('Survey','Survey'[Q1]+'Survey'[Q2]+'Survey'[Q3]))

 

I'd appreciate any help or guidance to resolve this query which will give me an individual % score per employee for each of the two surveys

 

Many thanks

1 ACCEPTED SOLUTION
dedelman_clng
Community Champion
Community Champion

You should unpivot your data such that you table looks more like

 

Emp  SurveyID  QuestID  Score

1        1             1             1

1        1             2             2

 

etc

 

This structure will make it much easier to get individual scores.

 

Hope this helps

David

View solution in original post

1 REPLY 1
dedelman_clng
Community Champion
Community Champion

You should unpivot your data such that you table looks more like

 

Emp  SurveyID  QuestID  Score

1        1             1             1

1        1             2             2

 

etc

 

This structure will make it much easier to get individual scores.

 

Hope this helps

David

Helpful resources

Announcements
Fabric Community Conference

Microsoft Fabric Community Conference

Join us at our first-ever Microsoft Fabric Community Conference, March 26-28, 2024 in Las Vegas with 100+ sessions by community experts and Microsoft engineering.

February 2024 Update Carousel

Power BI Monthly Update - February 2024

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

Fabric Career Hub

Microsoft Fabric Career Hub

Explore career paths and learn resources in Fabric.

Fabric Partner Community

Microsoft Fabric Partner Community

Engage with the Fabric engineering team, hear of product updates, business opportunities, and resources in the Fabric Partner Community.

Top Solution Authors