Tjeffriesppt Bi Portfolio
description
Transcript of Tjeffriesppt Bi Portfolio
TABLE OF CONTENTS
Project Overviews
T-SQL Samples
MDX Samples
SSIS – Integration Services
SSAS – Analysis Services
Calculated Members
KPI’s, Trend Indicators, and Excel Services – Samples
SSRS- Reporting Services
MOSS/PPS – Share Point and Performance Point Services
2
Timothy L. Jeffries 2009
PROJECT OVERVIEW
Sample Business Intelligence Project Work
This portfolio contains selected code that I have developed in the Microsoft
Business Intelligence area.
Overall technologies covered:
• Microsoft SQL Server 2005 T-SQL
• Microsoft SQL Server 2005 MDX
• Microsoft SQL Server 2005
• Microsoft SQL Server 2005 Integration Services (SSIS)
• Microsoft SQL Server 2005 Analysis Services (SSAS)
• Microsoft SQL Server 2005 Reporting Services (SSRS)
3
Timothy L. Jeffries 2009
PROJECT GOALS
• Define a Star Schema database using Visio
• Create a Staging Database (Visio generated script)
• Create an ETL solution to update the SQL Server 2005 database from Excel and
flat files using SSIS
• Create a Star Schema Analysis Services using SSAS
• Write MDX queries bases on criteria lay outs
• Define Calculated Members and business Key Performance Indicators (KPIs) in
SSAS
• Use Excel Services 2007 to display the cube data and the KPIs, displaying
statuses and trends
• Produce detail and summary reports using SSRS
• Create score cards using MS Office Performance Point
• Implement business intelligence dashboards using MOSS 2007 (SharePoint)
4
Timothy L. Jeffries 2009
T-SQL SAMPLES
5
Timothy L. Jeffries 2009
T-SQL SAMPLES
6
Timothy L. Jeffries 2009
T-SQL SAMPLES
7
Timothy L. Jeffries 2009
T-SQL SAMPLES
8
Timothy L. Jeffries 2009
T-SQL SAMPLES
9
Timothy L. Jeffries 2009
T-SQL SAMPLES
10
Timothy L. Jeffries 2009
T-SQL SAMPLES
11
Timothy L. Jeffries 2009
SSIS PROJECT
12
Timothy L. Jeffries 2009
These containers update and insert records for the Employee and Client tables
while reading the information form either an excel or flat file. If any of these packets
fail and email is sent out and everything is rolled back stopping the process.
T-SQL SAMPLES
13
Timothy L. Jeffries 2009
SSIS PROJECT
14
Timothy L. Jeffries 2009
Connected to the other two containers these containers continue the updates and
will send an email out once all the insert and updates are done. Then it does a
backup, shrink and index after everything is updated. Once the database
maintenance is finished then emails are send out.
SSIS PROJECT
15
Timothy L. Jeffries 2009
This is an example of an expression that sends out an email on success with
information about how the files in the package were processed and how many
failed, processed, and failed the conversion.
SSIS PROJECT
16
Timothy L. Jeffries 2009
This For each loop container will loop through all the files in the directory that is
specified and load all the files. The container is also programmed for error and
checks as seen below.
SSIS PROJECT
17
Timothy L. Jeffries 2009
In a nutshell this part of the project looks and converts the files to SQL format and
logs any errors. Then it looks up PK and put the ones not found into a file. Then it
checks the table to see if this is an insert or an update and then records how many
it does of each, all counts are running counts and are done in vb.net as shown
below.
SSIS PROJECT
18
Timothy L. Jeffries 2009
This is the setup so that we can pass in what we want to read in the script and then
what is coming back from the script. The script is explained below.
SSIS PROJECT
19
Timothy L. Jeffries 2009
This script runs every time what we process a file and then once the counts are
completed it copies the file to a done folder and deletes the other file. This is done
so we do not duplicate the files and so we do not lose them either.
SSAS – ANALYSIS SERVICES
Design the Data Source View using BIDS
• Create a cube in Adventure Works using fact tables and dimension tables
• Create a star diagram using the fact tables and dimension, a snowflake diagram will have dimension tables connected to
other dimension tables.
• This is the view prior to the cube being launched.
Timothy L. Jeffries 2009
20
SSAS – ANALYSIS SERVICES
Once the cube is created we now display the fact tables in yellow connected to the blue tables that are the dimensions.
This diagram shows all the fact tables pointing towards the PKs in the dimension tables.
This is an example of a snowflake diagram due to the points having multiple points on them.
A start diagram has on fact tables connected to dimension tables without dimension tables connected to them.
Timothy L. Jeffries 2009
21
SSAS – ANALYSIS SERVICES
After the cube is launched the wizard will build all the relationships and those that are not built must be done manually.
The tables in yellow are the fact tables and the ones in blue are the dimension tables.
All the fact tables have the FKs for the PKs in the dimension tables.
Timothy L. Jeffries 2009
22
SSAS – ANALYSIS SERVICES
Create reports in Excel using outside data and pivot tables.
Timothy L. Jeffries 2009
23
SSAS – ANALYSIS SERVICES
24
Timothy L. Jeffries 2009
This will also let you filter, notice that the filter is set to all males for sales.
KPI EXAMPLES
25
Timothy L. Jeffries 2009
KPI EXAMPLES
26
Timothy L. Jeffries 2009
KPI EXAMPLES
27
Timothy L. Jeffries 2009
KPI EXAMPLES
28
Timothy L. Jeffries 2009
KPI EXAMPLES
29
Timothy L. Jeffries 2009
MDX EXAMPLES
30
Timothy L. Jeffries 2009
Simple MDX example that show MA, PA, and NY dollar and unit sales for Q1 and Q2
MDX EXAMPLES
31
Timothy L. Jeffries 2009
Displays the different level of Hierarchy levels staring with the first parent, then
second parent, then the tools level and then finally to the children of the tools for the
3 months in the 3rd quarter.
MDX EXAMPLES
32
Timothy L. Jeffries 2009
Uses a member to create a calculated member so we can see the difference in
Dollar Sale, Unit Sales, and Dollar Returns for the first two quarters.
MDX EXAMPLES
33
Timothy L. Jeffries 2009
Shows how to filter using the columns where the unit sales is greater in Q4, 2005 are
greater 1.4 times Q4, 2004 displaying the Dollar sales for Q4, 2005
MDX EXAMPLES
34
Timothy L. Jeffries 2009
Creates Avg Price, Max Avg Price, Price Range, and Min Avg Price then displays Q3
and Q4 and Cross joins that Calculated prices together for all the children of Home
Audio.