• Status: Solved
  • Priority: Medium
  • Security: Public
  • Views: 77
  • Last Modified:

SSRS Graph X-Axis number to month name

Hi all, I'm having a problem changing the X-Axis labels from a number to text; such as 1 to January, 2 to February, etc...
I've tried a number of things but the best I can get is that each number is change to text but it is the same text.  So 1,2,3,4,5,6, etc.. are all showing January.  I've create =Switch expressions and used the =MonthName(Fields!MONTH.Value, True) in the Format applet which shows all pints as "Jan".

I'm using SQL 2012.
Any help would be wonderful.
Thanks,
John.
0
Thunder724
Asked:
Thunder724
  • 3
1 Solution
 
Chris LuttrellSenior Database ArchitectCommented:
Try one of these:
=Format(Fields!MONTH.Value,"MMMM")
or
=Switch(Fields!MONTH.Value = 1, "January",
                   Fields!MONTH.Value = 2, "February",
                   Fields!MONTH.Value = 3, "March"................)
this came from http://www.sql-datatools.com/2015/05/ssrs-how-to-convert-month-number-into.html
0
 
Thunder724Author Commented:
I figured it out in part.  I had to make sure the Category was set and that Axis range and intervals where set correctly; being Side Margins: Auto, Interval: 1, and interval type: Default.
That said I included a column in my stored procedure to be the textural name of the month too.

I am having difficulty figuring out one other graph in the same regards because the series is an expression not a column.
0
 
Thunder724Author Commented:
I got the last piece done the same as above; just had a query issue.
0
 
Thunder724Author Commented:
I figured it out in a much different way presented.  I also had tried the suggestion provided prior to asking this question and it did not work because the answer was not related to a graph; but an expression for non graph objects.
0

Featured Post

Free Tool: SSL Checker

Scans your site and returns information about your SSL implementation and certificate. Helpful for debugging and validating your SSL configuration.

One of a set of tools we are providing to everyone as a way of saying thank you for being a part of the community.

  • 3
Tackle projects and never again get stuck behind a technical roadblock.
Join Now