views:

213

answers:

1

Hi all,

I have a chart I'm making in SSRS.

My database is returning data like this:
Period Name, Question, Answer, Count, Mean, Median
Nov 09, Can Haz Chezbrgr, Yes, 5, 4, 3.1
Nov 09, Can Haz Chezbrgr, No, 3, 4, 3.1
Nov 09, Can Haz Chezbrgr, DK, 2, 4, 3.1

Period Name is the primary grouping, question is the same for all rows. Answer varies as does count. The mean and median are calculated based on period name & count, but are the same for all values in each period.

I have a chart in SSRS that's plotting the Answers by period. I'm trying to add the mean as a single plotted item. The problem is that the mean text is showing up once for each answer in the legend, but only once in the chart (this makes sense since the values are all the same.

Here is an example chart:

Chart

Here is what my report definition looks like:

Chart

Ideally, I'd like to have only one entry in the legend for Mean, with no association to the answer. Is this possible?

Thanks for your help!

A: 

With help from Jerry Nee as the MSDN SSRS forums, I've got a solution.

Briefly, the solution is:
1. Right-click a blank area on the chart to get the "Series Properties (NAME)", where name is the name of the series.
2. Go to the Legend page and enter a custom legend of "Mean"
3. Edit the function for "Do not show this series in a legend"
4. The expression is, =IIF(Fields!RowAnswerText.Value=Last(Fields!RowAnswerText.Value,"DataChart"),false,true)

Thanks to Jerry for the help with this. Right now I'm trying to do the same thing with the label, but it isn't working for me...

Ben