SSRS: How to improve the presentation of labels on a pie diagram? - reporting-services

I have a circular diagram and I am using the keyword #PERCENT to present the percentages of the different categories. But sometimes the labels overlap.
enter image description here
I have tried different tag property settings but i can't fix it.
I have also tried to configure an expression, but it generates an error:
=IIf( Cint(#PERCENT) < 1 , "", #PERCENT )
How can I improve the presentation?
Thank you! in advance

There are a few things you can do.
To fix what you are already trying to do you need to change your expression to something like
= IIF(
SUM(Fields!Amount.Value) / SUM(Fields!Amount.Value, "DataSet1") <0.01,
0,
"#PERCENT"
)
The assumes the pie chart is based on a fields called Amount and your dataset is called DataSet1 .
Then you need to set the Format property of the datalabel to something like
0.00;(0.00);' '
It's the part after he last colon that is important here ;' ' means, show zero's as a space.
You could set the label position to Outside so tey are not as close togther
You could "Explode" the small slices into another pie or move the these slices away from the main pie by setting the CollectedStyle in the CustomAttributes property group
in the example below this says "any slices that are <=20% or the chart" move them into their own mini chart.
Look at the SmartLabels property group in the Chaer Series properties.
Hopefully with this info you will have enough to improve your chart.

Related

SSRS Chart Title - change font size for a part of the title

I have a situation in which I have developed a visual chart in SSRS
2012. The chart title is fixed -
Schools Performance in MyCity (County, State, Country)
(Remember, the above title is NOT dynamic, so the situation is easy to handle.)
(1) I need to keep the first part :
Schools Performance in MyCity (left 30 characters) at a font size of 12, Bold
(2) I need to keep the second part starting from the bracket "(" and ending in the other bracket ")" :
(County, State, Country) (all characters after the left 30 characters) at a font size of 8, non-Bold and italic.
I am not able to use multiple title boxes due to space constraint in the chart
I need to get the equivalent of some T-SQL string functions such as CHARINDEX, PATINDEX, etc. in SSRS. I am not too familiar with string functions inside SSRS.
Can anyone provide me a solution on how to achieve my goal?
Any suggestion will be greatly appreciated.
I think the best way here is you delete your chart title and add a textbox above your chart. In this textbox you can write your text with the desired formating (Home Tab > Font). If SSRS rearanges the position of the textbox and the chart, put the chart and the textbox in a rectangle, so they stay where you place them.
As far as I know rich text or formating in the title is not possible.

Vary the colors of same-series data markers in a chart in SSRS

Hello I have a Column Chart in SSRS . There is only one data series. I want to give green color for top 4 and blue colors for the rest ones in this series as you can see in the picture.This is an image that ı want to make but when ı prepare a "custompalettecolors" it still gives all the column same color.(I think this is for charts with different series but ı have only one series and many columns).So can you give me some advice for this ?
I believe you can by using a formula in the fill if you have someway in the data to specify the top 4. On fill properties for the series:
Now the question is: What goes in the formula? You'll need something in your data that ranks the items. so, that you could create a formula like this:
=iif(Fields!Ranking.Value<=4,"Green","Blue")
I would do this in my T-SQL. Not seeing your dataset, I can't tell you exactly how to proceed. I hope this gets you started

SSRS single bar-chart

Good day all,
Please am trying to create a SSRS report that looks like the image below
i have my table structure in this manner
Please note the data are not in relation with the chart
But all i could get as a result is a multiple bar chart. that resembles the image below.
Thanks in anticipations of your response
First of all, your "Balance on COC" is negative. That's probably not just a chart visualization issue.
You can format the numbers on the y-axis to be more readable like they are in your first screenshot. Click on the Chart Axis and set the LabelsFormat property to #,0;(#,0).
While numbers in the chart can have up to 16 digits, that is highly unreadable for most people. You might want to consider visualizing the numbers in Billions instead.
To get the labels on the x-axis you'll need to set that field as the Category Group. Then you can delete the legend area from the chart. You can also remove the "Axis Title" areas since they are not needed in this case. This will all make it look more polished like the other image.

SSRS Chart Custom Legend

I have a pie chart like this
However, I'd like it to look like this (i.e. left-aligned text, right aligned values within the label)
It doesn't seem possible in SSRS, which is a problem - can anyone help?
Sure it is!
Right click your series group -> Series Group Properties...
Insert the appropriate calculations into the label expression. I've done similar things like adding counts to the axis labels on bar charts.
EDIT: I feel like your best bet for these alignments is to create a small table next to the chart. It's an awkward solution, but here's an example I threw together to show it can kinda be done. You just have to make sure they are sorted the same. You can use a group + dataset to get your values. It's a very brittle fix, but it works.

Hide Duplicate Legend Items in SSRS Report Chart

I have a stacked column chart in SSRS that displays data by hour. Included in this data is the meters reading, kVa, Average Temperature and Heat Index for that hour. For some reason, the legend items for the temperature values and the kVa are being repeated for each meter in the dataset. I would like for my legend to have the following values: kVa, Average, Heat Index and each meter number. I included a sample of the chart, the chart data configuration as well as some sample data below. Any idea how I can accomplish this? Please let me know if any other information is required.
Here is a good solution which covers all possible scenarios
go to "Report Properties" (right click in the blank area)
go to variables and add a new variable called myflag, set the value to "true" and deselect Read-Only
go to the "Series Properties" and then to "Legend" and click the expression button next to "Do not show this series in legend"
Type or paste this code:
=IIF( Variables!myflag.Value = true, false, true )
=Variables!myflag.SetValue( false )
and that's it.
hint
You can use the same variable in the same series' visibility expression without the setting part in the second line to avoid overlapping the drawing of the same series on the chart
I couldn't get either of these answers to work for me. Ended up using RowNumber and CountRows in the expression for Do not show this series in a legend property.
=IIF(RowNumber("Dataset")=CountRows(),false,true)
You're getting one set of legend values per series you've added. For each series besides the one whose legend you want to keep visible, right click the series (each top-level row in the "Values" box), choose Series Properties, go to the Legend tab, and check "Do not show this series in a Legend."
I was able to fix my issue using information from this question on stack overflow: https://stackoverflow.com/a/1867343/965213
Go to the Legend page of the series properties you want to include in the chart.
Edit the function for the "Do not show this series in a legend" property.
Use this formula: =IIF(Fields!SerialNumber.Value=Last(Fields!SerialNumber.Value,"MeterDetail"),false,true)
Now the series will only be repeated once instead of once per series group.
Hope this helps!