Amira Bedhiafi
Amira Bedhiafi

Reputation: 1

Power BI : Addcolumns and summarize

I'm trying to get the number of vote records depending on the satisfaction of our customers. For example :

This is a part of my dataset : enter image description here

I want to have for each Opp title , the number of records having X votes with X a scale from 1 to 10.

The X is the response of the customer for the How likely would you recommend the experience you lived? as shown in the dataset, in the last column.

I made a new table with this query where I added Flag to know if it's POOR , MEDIUM or High, but I'm not getting the requested result :

Summarize Table = 
ADDCOLUMNS (
    SUMMARIZE(
        NPS_18_7_2018;NPS_18_7_2018[Opp title];
        "Total order"; DISTINCTCOUNT ( NPS_18_7_2018[How likely would you recommend the experience you lived?])
    );
    "Flag"; IF ( [Total order] <= 5; "POOR"; IF ( [Total order] = 5; "Medium"; "High" ) )
)

I'm trying to generate a chart where I can find for the VOTE = 5/10 for example , the number of EP ID who voted 5/10 for each Opp title.

One of the incorrect records I get as a result:

enter image description here

Upvotes: 1

Views: 619

Answers (3)

Amira Bedhiafi
Amira Bedhiafi

Reputation: 1

The problem was with the name of the dataset which is Data and not NPS_18_7_2018

Summarize Table =
        SUMMARIZE(
            Data;
            Data[Opp title];
            Data[How likely would you recommend the experience you lived?];
            "Votes"; COUNT(Data[EP ID])
        )

Upvotes: 0

Amira Bedhiafi
Amira Bedhiafi

Reputation: 1

I realized that after the Power BI updates , I was looking for the Slicers. I created a new slicer then select the data field to filter on :

  • Opp title
  • How likely would you recommend the experience you lived?
  • ...

You can see documentation here : Slicers in Power BI

Upvotes: 0

Alexis Olson
Alexis Olson

Reputation: 40304

I think this would match your question more closely:

Summarize Table =
    SUMMARIZE(
        NPS_18_7_2018;
        NPS_18_7_2018[Opp title];
        NPS_18_7_2018[How likely would you recommend the experience you lived?];
        "Votes"; COUNT(NPS_18_7_2018[EP ID])
    )

This groups by title and rating and then count applies the count.

Upvotes: 2

Related Questions