Question

I am having a problem with getting a stacked area chart to display the right data in SSRS 2005.

On my Y axis, I want a scale from 50% to 100%. On my X axis I have a set of dates formatted in a style that was necessary for the report (so varchar). My data consists of 3 data fields which are decimal numbers and contained between 0 and 1, each with a specific date.

My problem is the scale of the Y-axis. I have set the maximum value to 100, the minimum to 50, the interval to 5, and the format to "p" for percentages.

On the preview in the layout tab, this all appears fine (Y-axis starting at 50% up to 100%). However whenever I generate an actual report it goes from 5000% to 10000% for some reason. I have no idea how this is happening and it completely ruins the report.

I have tried tinkering in the properties for several hours but to no avail.

If this has happened to anyone and they have found a solution, or if anyone has any suggestions I would be very grateful.

Thanks.

Was it helpful?

Solution

When you use percentages, everything factors by 100.

If you want to format and display a value as 50% , it needs to be 0.5 unformatted. Percentages are therefore values between 0 and 1. Excel and pretty much every other tool works that way.

If your values are all stored as percentages already, then you might just want to append the % symbol at the end of your values. Or better, divide everything by 100. 50 per cent means just that anyway; it means 50 per hundred (cent means 100) so 50/100 is another way of writing 50%.

Licensed under: CC-BY-SA with attribution
Not affiliated with StackOverflow
scroll top