Reporting Service months in x-axis - reporting-services

I have a bar chart that shows values for each month in the year. Therefor my bar chart has 12 values on the x-axis. Now they show the numbers 1-12 but I would like instead of numbers to show the name of each month "Jan"-"Dec" or "January"-"December". How do I do this?
Thanks

If you use the month number try set label x-axis to this:
Or you can create a calculated field in the dataset and set it to the above expression then use that field in the x-axis label.
EDIT: I reproduced a possible scenario of your chart.
This is a chart with month number in x-axis, according to your description it is what you are getting now:
The easiest way to get the month name is using a calculated field:
Right click on dataset, go to Fields tab, click add button and type the name to the field in this case MonthName
In Field Source click on right side button Fx for set the expression
and add the following expression:
=Switch(
Fields!MonthNumber.Value=1,"January",
Fields!MonthNumber.Value=2,"February",
Fields!MonthNumber.Value=3,"March",
Fields!MonthNumber.Value=4,"April",
Fields!MonthNumber.Value=5,"May",
Fields!MonthNumber.Value=6,"June",
Fields!MonthNumber.Value=7,"July",
Fields!MonthNumber.Value=8,"August",
Fields!MonthNumber.Value=9,"September",
Fields!MonthNumber.Value=10,"October",
Fields!MonthNumber.Value=11,"November",
Fields!MonthNumber.Value=12,"December",
)
Click Ok, and update your chart to use the MonthName field (not the MonthNumber)
Right click on MonthName in Category Groups Properties.
In sorting tab you should sort by MonthNumber, in my case is [Numero Mes] as follows:
After this you should get the following chart preview.
Let me know if this was helpful.

Related

How to get the Month and Year to show up together in SSRS

I am having some trouble with trying to get the year to show up alongside the month name in SSRS 2012.
I have tried changing the number to date and select different options but none seem to be working. I have also tried changing the number to date in the Text Box Properties and in the Placeholder Properties but no luck. Any ideas?
Picture of the issue
Providing that the field is in a date format, select text box properties, select number,select date category, select "January 2000" from the Type list box.
Select text box, go to the properties window (F4) and type MMMM yyyy into the Format section

How to return value of unbound column in combo box

How can I get the value of an unbound column of a combo box using the expression builder in Access 2007?
I have a form that controls a query through a combo box where I select a month on the form and Access runs a query for items pertaining to that month. Then I have a report that based on that query.
I'd like the report header to display the month that was selected. I made a text box in the report that uses an expression as the control source like so "=[Forms]![frm Annual Notices Report]![Combo10]". Which works expect it returns the value in Col1. How can I make my text box display the month in Col2? I've tried "=[Forms]![frmMyform]![Combo10(1)]", but it returns an error.
My combo box is setup like this:
Col1 Col2
1 January
2 February
3 March
4 April
... ...
I need to use the month index to control the query, but I also want to make a text box in a report show the month as written.
TL;DR:
How can I make a text box display the month in Col2?
Currently I have this: "=[Forms]![frmMyForm]![Combo10]"
I think I need something like this: "=[Forms]![frmMyform]![Combo10(1)]"
You need the .Column property.
=[Forms]![frmMyForm]![Combo10].Column(1)
is the second column.
BTW, there is also the MonthName() function.

How to show q[1-4] for month quater in range bar chart in x-axis in ssrs

I have created a range bar chart in ssrs. I want to show x-axis label in quater format i.e q1 for jan,q2 for apr,q3 for july,q4 for oct
Here is the screenshot. I need to change from Month Jan-Q1.
I know nothing about your dataset fields so I am guessing.
Try this expression in x-axis labels:
=Switch(
Fields!Month.Value="Jan","Q1",
Fields!Month.Value="Apr","Q2",
Fields!Month.Value="Jul","Q3",
Fields!Month.Value="Oct","Q4"
)
EDIT: Add expression to label x-axis in range chart.
Right click on Category Groups Collection (in my case Month)
In general tab go to label textbox and add the expression.
Input the expression I provided you. (In my case Month is the calendar number of year, you should use the above expression)
This is the preview.
Let me know if this was helpful.

How to percentage and count in SSRS Pie Chart

I have a Pie chart generated using SSRS. I would like to Show both Count and percentage in the Pie chart.
Right now, I am able yo show the count in pie charts as well as in the report.
I want to show the name of the partition and also the percentage directly pointed out.
Example :
ALD 38% 56
please help me withe properties to do it.
I'm using VS 2008
1-right click on chart and select "show data label"
2-right click on label an select "series label properties"
3- general -> label data -> set this value = "#PERCENT (#VALY)"
4- it will be like this screenshot
write down an expression on series label data like -
=Sum(Fields!DATA.Value, "Chart1_SeriesGroup1") & "("
& Sum(Fields!DATA.Value, "Chart1_SeriesGroup1") * 100 /Sum(Fields!DATA.Value, "DataSet1")
& "%)"
Here Chart1_SeriesGroup1 is the group name if you look at series group setting
Here DataSet1 is the name of Dataset
Here is the final output
Cheers :-)
In the label Properties type "#PERCENT" in Label Data
This can be used on its own or in conjunction with the other value itself by adding "#PERCENT(#VALY)"
Place this in quotes if you are trying to concat other values with it. For instance, this would show the label with the accompanying percent below
=First(Fields!Data.Value, "Chart_Group") & vbcrlf & "#PERCENT"
Where "Chart_Group" is the name of the grouped on field

SSRS - Replace the Chart

I have a question, want some assistance.
Q) My question is that i have a chart in which analyst assigned for many incidents and some analyst have 1 or two incident assigned. just because of this the bar chart looks ugly some time. So thats why i used a new chart to represent Min incident count. But i want there some creativeness, for which i want there a radio button or OnClick event ( I do not know how to use both these. When report runs by default it`ll show Max incidents count chart and when we used radio button it will show Min incidents count chart, on the same chart area no need of new area or on new page.
Kindly help me or refer me some links and with ideas. As i have searched many blogs but i didn`t get any big achievement.
Below is my Simplified query;
SELECT
Count(IncidentDimvw.Id)
,UserDimvw.FirstName AS Analyst
FROM
IncidentDimvw
FULL JOIN WorkItemDimvw
ON IncidentDimvw.EntityDimKey = WorkItemDimvw.EntityDimKey
JOIN WorkItemAssignedToUserFactvw
ON WorkItemDimvw.WorkItemDimKey = WorkItemAssignedToUserFactvw.WorkItemDimKey
JOIN UserDimvw
ON WorkItemAssignedToUserFactvw.WorkItemAssignedToUser_UserDimKey = UserDimvw.UserDimKey
WHERE
WorkItemAssignedToUserFactvw.DeletedDate IS NULL
GROUP BY
UserDimvw.FirstName
Having (Count(IncidentDimvw.Id) = (#Count))
Having Clause is right or wrong, i donot know.
I used the following expresion in series as you suggested.
=iif(Parameters!Count.Value, Max(Sum(Fields!ID.Value)), Min(Sum(Fields!ID.Value)))
Sample data is as folows;
Regards
Muhammad Ahsan
I can think of a couple of ways to approach this:
Dynamic expressions based on parameter
Say you have a simple DataSet like:
And also a boolean parameter called showMax.
We can create a simple bar graph based on this:
The most important thing to note is that Series value is expression-based:
In the above example the expression is:
=IIf(Parameters!showMax.Value
, Max(Fields!value.Value)
, Min(Fields!value.Value))
i.e. when showMax is true, report the Max values, otherwise report the min values.
In this case I've also updated the Axis title, Chart title, and Custom legend text to be expression-based:
Axis Title: =IIf(Parameters!showMax.Value, "Max", "Min")
Chart Title: =IIf(Parameters!showMax.Value, "Max per group", "Min per group")
Custom legend text: =IIf(Parameters!showMax.Value, "Max value", "Min value")
The chart behaviour changes based on what parameter is selected as required:
Set Visibility based on parameter
Another option is simply to have to charts and hide one depending on parameter selection.
For example, for the Max chart the Hidden property can be set to:
=Not(Parameters!showMax.Value)
Setting this property correctly for each report will mean only one is ever displayed to the user, i.e. it will look dynamic.
Either of these options should work; the first keeps the layout simple in the designer makes the chart more complex, the second makes the layout more complex but keeps the charts simple.
Hopefully one option will work for you.