Link to home
Start Free TrialLog in
Avatar of CodeJunky
CodeJunkyFlag for United States of America

asked on

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.
Avatar of Chris Luttrell
Chris Luttrell
Flag of United States of America image

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
ASKER CERTIFIED SOLUTION
Avatar of CodeJunky
CodeJunky
Flag of United States of America image

Link to home
membership
This solution is only available to members.
To access this solution, you must be a member of Experts Exchange.
Start Free Trial
Avatar of CodeJunky

ASKER

I got the last piece done the same as above; just had a query issue.
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.