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

Register now to learn Fabric in free live sessions led by the best Microsoft experts. From Apr 16 to May 9, in English and Spanish.

Reply
Anonymous
Not applicable

Display a value on a bar chart other than the one explicitly put into value field

I have a table containing the following information in its columns: a product, a month, a quantity number and a satisfaction percentage. What I would like to do is display this information in a bar chart such as having the month on the x axis, the product in the legend, the quantity in the values. So far so good, this works perfectly fine.

 

Additionally to that I would like to display the average satisfaction percentage permanently for each month (or, even better, for each month AND product). If I put it in a quickinfo it works fine, but this is obviously not a permanent display.

 

I already tried using a combo chart with bar and line, however if I filter on a specific product the line with the satisfaction percentage does not update accordingly (while the quick info values do).

1 ACCEPTED SOLUTION
v-alq-msft
Community Support
Community Support

Hi, @Anonymous 

 

Based on your description, I created data to reproduce your scenario.

Table:

b1.png

 

DateTable(a calculated table):

 

DateTable = CALENDARAUTO()

 

 

You may create a relationship between two tables.

 

Then you can create a measure as follows.

 

Average satisfaction percentage = 
CALCULATE(
    AVERAGE('Table'[Satisfaction percentage]),
    FILTER(
        ALLSELECTED(DateTable),
        DateTable[Date].[Year] = MAX('DateTable'[Date].[Year])&&
        DateTable[Date].[Month] = MAX(DateTable[Date].[Month])
    )
)

 

 

Finally you may use 'Line and clustered column chart' visual to display the result. Make sure you click the 'Expand all down one level in the hierarchy'.

b2.png

 

Best Regards

Allan

 

If this post helps, then please consider Accept it as the solution to help the other members find it more quickly.

 

View solution in original post

1 REPLY 1
v-alq-msft
Community Support
Community Support

Hi, @Anonymous 

 

Based on your description, I created data to reproduce your scenario.

Table:

b1.png

 

DateTable(a calculated table):

 

DateTable = CALENDARAUTO()

 

 

You may create a relationship between two tables.

 

Then you can create a measure as follows.

 

Average satisfaction percentage = 
CALCULATE(
    AVERAGE('Table'[Satisfaction percentage]),
    FILTER(
        ALLSELECTED(DateTable),
        DateTable[Date].[Year] = MAX('DateTable'[Date].[Year])&&
        DateTable[Date].[Month] = MAX(DateTable[Date].[Month])
    )
)

 

 

Finally you may use 'Line and clustered column chart' visual to display the result. Make sure you click the 'Expand all down one level in the hierarchy'.

b2.png

 

Best Regards

Allan

 

If this post helps, then please consider Accept it as the solution to help the other members find it more quickly.

 

Helpful resources

Announcements
Microsoft Fabric Learn Together

Microsoft Fabric Learn Together

Covering the world! 9:00-10:30 AM Sydney, 4:00-5:30 PM CET (Paris/Berlin), 7:00-8:30 PM Mexico City

PBI_APRIL_CAROUSEL1

Power BI Monthly Update - April 2024

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

April Fabric Community Update

Fabric Community Update - April 2024

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