SSRS - Chart with two Vertical (Y) axes - Primary and secondary Vertical axes

This article is about an example for creating Chart with two Vertical (Y) axes - Primary and secondary Vertical axes .

Step 1: Create Data source and then create Dataset with below query :

--Sample data
DECLARE @Tmp TABLE (Projects VARCHAR(20),SQLServer2008 INT,SQLServer2012 INT)
INSERT @Tmp SELECT 'P101',100,1000
INSERT @Tmp SELECT 'P102',500,1500
INSERT @Tmp SELECT 'P103',1000,200
SELECT * FROM @Tmp


Step 2 :
Drag&drop Chart from Toolbox or right-click on report body - > Insert - > Chart .
Add a Line chart :



Step 3 :  Double - click on the chart area , you will notice Chart Data , Under Chart Data
for summation Values add SQLServer2008 and SQLServer2012 columns from Dataset and then for Category Groups add Projects column from the Dataset .

To add Secondary vertical axis :

Step 4 : Under Chart Data , right-click on SQLServer2012 (second summation value) - >  Series Properties ... - > Axes and Chart Area - > Vertical axis - > Secondary , as shown in below images :



 Click on Preview Pane :

No comments: