Quantcast
Channel: SQL Server Reporting Services, Power View forum
Viewing all articles
Browse latest Browse all 20764

SSRS Switch Function

$
0
0

Hi All,

With my code below I am attempting to change labels on the Horizontal Chart axis to reflect the assigned values but my code seems not work as the chart still returns (Month 1,Month 2) instead of (Jan,Feb,Mar etc)...please review my code below maybe I am missing something. I inserted this code under the category group Label.

=Switch(Fields!Month_Of_Year.Value = "Month 1","Jan",
Fields!Month_Of_Year.Value = "Month 2","Feb",
Fields!Month_Of_Year.Value = "Month 3","Mar",
Fields!Month_Of_Year.Value = "Month 4","Apr",
Fields!Month_Of_Year.Value = "Month 5","May",
Fields!Month_Of_Year.Value = "Month 6","Jun",
Fields!Month_Of_Year.Value = "Month 7","Jul",
Fields!Month_Of_Year.Value = "Month 8","Aug",
Fields!Month_Of_Year.Value = "Month 9","Sep",
Fields!Month_Of_Year.Value = "Month 10","Oct",
Fields!Month_Of_Year.Value = "Month 11","Nov",
Fields!Month_Of_Year.Value = "Month 12","Dec")

The dataset is shown below:

Dataset

Chart Grouping:

Chart Data Grouping

Your insight is highly appreciated. Many Thanks.


The Best thing in Life is Life


Viewing all articles
Browse latest Browse all 20764

Trending Articles



<script src="https://jsc.adskeeper.com/r/s/rssing.com.1596347.js" async> </script>