Database Journal
MS SQL Oracle DB2 Access MySQL PostgreSQL Sybase PHP SQL Etc SQL Scripts & Samples Links Database Forum

» Database Journal Home
» Database Articles
» Database Tutorials
MS SQL
Oracle
DB2
MS Access
MySQL
» RESOURCES
Database Tools
SQL Scripts & Samples
Links
» Database Forum
» Sitemap
Free Newsletters:
DatabaseDaily  
News Via RSS Feed


follow us on Twitter
Database Journal |DBA Support |SQLCourse |SQLCourse2
 

Featured Database Articles

MS SQL

Posted May 21, 2009

Stacked Bar Chart for Analysis Services Data - Page 6

By William Pearson

  1. Click the Data Output tab of the Edit Chart Value dialog.

The Data Output tab affords us a means of defining XML data output options for the values in the chart. We will not leverage these capabilities within this introduction to simple Column charts, and will therefore leave the settings of the Data Output tab at their defaults, as shown in Illustration 25.

The Data Output Tab with Default Settings
Illustration 25: The Data Output Tab with Default Settings

  1. Click the OK button at the bottom of the Edit Chart Value dialog, to dismiss the dialog with our settings.

We are returned to the Data tab of the Chart Properties dialog. Next we will work with the Category groups area of the tab, just under the Values area. Categories are optional, and are displayed as bars or groups of bars on the Y-axis. Multiple groups are nested, as we shall see within our current practice example.

  1. Click the Add... button to the right of the Category groups list box, found immediately underneath the Values list box with which we worked above.

The Grouping and Sorting Properties dialog appears, defaulted to the General tab.

  1. Type (or cut and paste) the following into the Name box, atop the General tab:
	Year
  1. Click the top row of the Expression box within the Group on section that appears just underneath the Name box, to enable the selector button (the downward-pointing arrow) on the right side of the box.
  2. Select =Fields!Calendar_Year.Value from the options that appear, as depicted in Illustration 26.

Select =Fields!Calendar_Year.Value in the Top Row of the Expression List
Illustration 26: Select =Fields!Calendar_Year.Value in the Top Row of the Expression List ...

Because we have no input for the Filters or Data Output tabs (which resemble their counterparts in other areas of the Report Designer, as we have, and shall, see), within the context of this newly added group, and as we intend to leave the Sorting at the settings naturally found within the cube structure (the Calendar Years will sort in numerical order), we will accept our input at this stage.

The Grouping and Sorting Properties dialog appears, with our modifications, as shown in Illustration 27.

The Grouping and Sorting Properties Dialog with Our Modifications
Illustration 27: The Grouping and Sorting Properties Dialog with Our Modifications

  1. Click the OK button at the bottom of the Grouping and Sorting Properties dialog, to save our settings and to dismiss the dialog.

We are returned to the Data tab of the Chart Properties dialog. Next we will add another Category group to our report.

  1. Click the Add... button to the right of the Category groups list box, just as we did before.

The Grouping and Sorting Properties dialog appears, once again, defaulted to the General tab.

  1. Type the following into the Name box, atop the General tab:
	Territory
  1. Click the top row of the Expression box within the Group on section, once again, to enable the selector button (the downward-pointing arrow) on the right side of the box.
  2. Select =Fields!Sales_Territory_Group.Value from the options that appear, as depicted in Illustration 28.

Select =Fields!Sales_Territory_Group.Value in the Top Row of the Expression List
Illustration 28: Select =Fields!Sales_Territory_Group.Value in the Top Row of the Expression List ...

The Grouping and Sorting Properties dialog appears, with our modifications, as shown in Illustration 29.

The Grouping and Sorting Properties Dialog with Our Modifications
Illustration 29: The Grouping and Sorting Properties Dialog with Our Modifications

As we have no input for the Filters or Data Output tabs within the context of this newly added group, and as we intend to leave the Sorting at the settings naturally found within the cube structure (the Territory Groups will sort in alphabetical order), we will accept our input at this stage, just as we did with the previously added Category group, Year.

  1. Click the OK button at the bottom of the Grouping and Sorting Properties dialog, to save our settings and to dismiss the dialog.

We are returned to the Data tab of the Chart Properties dialog, once again. Our next step will be to add another group – this time an optional Series group. Series’ are displayed as sections within bars in the Stacked Bar chart. Each series is also displayed in the chart legend. At this point, we will add a Series group to contain the Sales Reason (Manufacturer, On Promotion, Price, etc.) that is associated with each of the grouped Internet Sales totals that the report will present.

  1. Click the Add... button to the right of the Series groups list box, just as we did in making our two Category groups entries earlier.

The Grouping and Sorting Properties dialog appears, once again, defaulted to the General tab.

  1. Type (or cut and paste) the following into the Name box, adding an underscore ( “_” ) character between the two words of the Name, atop the General tab:
	Sales_Reason
  1. Click the top row of the Expression box within the Group on section, yet again, to enable the selector button (the downward-pointing arrow) on the right side of the box.
  2. Select =Fields!Sales_Reason.Value from the options that appear, as depicted in Illustration 30.

Select =Fields!Sales_Reason.Value in the Top Row of the Expression List
Illustration 30: Select =Fields!Sales_Reason.Value in the Top Row of the Expression List ...

The Grouping and Sorting Properties dialog appears, with our modifications, as shown in Illustration 31.

The Grouping and Sorting Properties Dialog with Our Modifications
Illustration 31: The Grouping and Sorting Properties Dialog with Our Modifications

Because we again have no input for the Filters or Data Output tabs within the context of this newly added group, and as we intend to leave the Sorting at the settings naturally found within the cube structure (the Sales Reasons will sort in alphabetical order), we will accept our input at this stage, just as we did with the previously added Category groups, Year and Territory.

  1. Click the OK button at the bottom of the Grouping and Sorting Properties dialog, to save our settings and to dismiss the dialog.
  1. We return to the Data tab, once again, which appears, with our Values, Category groups, and Series groups settings, as depicted in Illustration 32.

Chart Properties Dialog Box – Data Tab with Our Settings
Illustration 32: Chart Properties Dialog Box – Data Tab with Our Settings

We will move to the X Axis tab in the subsection that follows.



MS SQL Archives

Comment and Contribute

 


(Maximum characters: 1200). You have characters left.

 

 




Latest Forum Threads
MS SQL Forum
Topic By Replies Updated
SQL 2005: SSIS: Error using SQL Server credentials poverty 3 August 17th, 07:43 AM
Need help changing table contents nkawtg 1 August 17th, 03:02 AM
SQL Server Memory confifuration bhosalenarayan 2 August 14th, 05:33 AM
SQL Server Primary Key and a Unique Key katty.jonh 2 July 25th, 10:36 AM


















Thanks for your registration, follow us on our social networks to keep up-to-date