Excel Power Pivot Tutorial PDF
Excel Power Pivot Tutorial PDF
Audience
This guide targets professionals with hands-on experience with Excel, to perform the high-
end data analysis and decision making in a matter of few minutes.
Prerequisites
Before you proceed with this tutorial, we are assuming that you are already aware about
the basics of Excel. If you are not well aware of these concepts, then we will suggest you
to go through our short tutorials on Excel charts and MS Access.
All the content and graphics published in this e-book are the property of Tutorials Point (I)
Pvt. Ltd. The user of this e-book is prohibited to reuse, retain, copy, distribute, or
republish any contents or a part of contents of this e-book in any manner without written
consent of the publisher.
We strive to update the contents of our website and tutorials as timely and as precisely as
possible, however, the contents may contain inaccuracies or errors. Tutorials Point (I) Pvt.
Ltd. provides no guarantee regarding the accuracy, timeliness or completeness of our
website or its contents including this tutorial. If you discover any errors on our website or
in this tutorial, please notify us at [email protected]
i
Excel Power Pivot
Table of Contents
About the Tutorial ............................................................................................................................................ i
Audience ........................................................................................................................................................... i
Prerequisites ..................................................................................................................................................... i
Copyright & Disclaimer ..................................................................................................................................... i
Table of Contents ............................................................................................................................................ ii
ii
Excel Power Pivot
iii
Excel Power Pivot
iv
1. Power Pivot – Overview Excel Power Pivot
Excel Power Pivot is an efficient, powerful tool that comes with Excel as an Add-in. With Power
Pivot, you can load hundreds of millions of rows of data from external sources and manage
the data effectively with its powerful xVelocity engine in a highly compressed form. This makes
it possible to perform the calculations, analyze the data, and arrive at a report to draw
conclusions and decisions. Thus, it would be possible for a person with hands-on experience
with Excel, to perform the high-end data analysis and decision making in a matter of few
minutes.
You will learn how to create Power PivotTables in the chapters – Creating a Power PivotTable
and Flattened PivotTables.
You will learn how to create Power PivotCharts in the chapter – Power PivotCharts.
5
Excel Power Pivot
DAX Basics
DAX is the language used in Power Pivot to perform calculations. The formulas in DAX are
similar to Excel formulas, with one difference – while the Excel formulas are based on
individual cells, DAX formulas are based on columns (fields).
You will understand the basics of DAX in the chapter – Basics of DAX.
Hierarchies
You can define data hierarchies in a data table so that it would be easy to handle related data
fields together in Power PivotTables. You will learn the details of the creation and usage of
Hierarchies in the chapter – Hierarchies in Power Pivot.
Aesthetic Reports
You can create aesthetic reports of your data analysis with Power Pivot Charts and/or Power
Pivot Charts. You have several formatting options available to highlight the significant data in
the reports. The reports are interactive in nature, enabling the person looking at the compact
report to view any of the required details quickly and easily.
You will learn these details in the chapter - Aesthetic Reports with Power Pivot Data.
6
2. Power Pivot – Installing Excel Power Pivot
Power Pivot in Excel provides a Data Model connecting various different data sources based
on which the data can be analyzed, visualized, and explored. The easy-to-use interface
provided by Power Pivot enables a person with hands-on experience in Excel to effortlessly
load data, manage the data as data tables, create relationships among the data tables, and
perform the required calculations to arrive at a report.
In this chapter, you will learn, what makes Power Pivot a strong and sought after tool for
analysts and decision makers.
If you have Excel 2010, POWERPIVOT tab might not appear on the Ribbon if you have not
already enabled the Power Pivot add-in.
Step 2: Click Options in the dropdown list. The Excel Options dialog box appears.
7
Excel Power Pivot
Click Add-Ins.
In the Manage box, select COM Add-ins from the dropdown list.
Click the Go button. The COM Add-Ins dialog box appears.
Check Power Pivot and click OK.
The Power Pivot Ribbon as shown below has various commands, ranging from managing Data
Model to creating reports.
8
Excel Power Pivot
The Power Pivot window will have the Ribbon as shown below-
The user-friendly interface of Power Pivot in the PowerPivot window enables you to perform
data operations without the knowledge of any database query language. You can then create
a report of your analysis within few seconds. The reports are versatile, dynamic and
interactive and enable you to further probe into the data to get the insights and arrive at the
conclusions / decisions.
The data that you work on in Excel and in the Power Pivot window is stored in an analytical
database inside the Excel workbook, and a powerful local engine loads, queries, and updates
the data in that database. Since the data is in Excel, it is immediately available to PivotTables,
PivotCharts, Power View, and other features in Excel that you use to aggregate and interact
with the data. The data presentation and interactivity is provided by Excel and the data and
Excel presentation objects are contained within the same workbook file. Power Pivot supports
files up to 2GB in size and enables you to work with up to 4GB of data in memory.
9
Excel Power Pivot
Ability to handle large data volumes, compressed into small files, with amazing speed.
Filter data and rename columns and tables while importing.
Organize tables into individual tabbed pages in the Power Pivot window as against the
Excel tables distributed all over the workbook or multiple tables in the same worksheet.
Create relationships among the tables, so as to analyze the data in the tables
collectively. Before Power Pivot, one had to rely on heavy usage of VLOOKUP function
to combine the data into a single table before such analysis. This used to be laborious
and error-prone.
Add power to the simple PivotTable with many added features.
Provide Data Analysis Expressions (DAX) language to write advanced formulas.
Add calculated fields and calculated columns to the data tables.
Create KPIs to use in PivotTables and Power View reports.
You will understand the Power Pivot features in detail in the next chapter.
You can create relationships between data tables so that you can perform data analysis on
the tables collectively. With DAX, you can write advanced formulas. You can create calculated
fields and calculated columns in the data tables in the Data Model.
10
Excel Power Pivot
You can define Hierarchies in the data to use everywhere in the workbook, including Power
View. You can create KPIs to use in PivotTables and Power View reports to show at a glance
whether performance is on or off target for one or more metrics.
You can share your workbook to a SharePoint environment that has Excel Services enabled.
On the SharePoint server, Excel Services processes and renders the data in a browser window
where others can analyze the data.
11
3. Power Pivot – Features Excel Power Pivot
The most important and powerful feature of Power Pivot is its database – Data Model. The
next significant feature is the xVelocity in-memory analytics engine that makes it possible to
work on large multiple databases in a matter of few minutes. There are some more important
features that come with the PowerPivot Add-in.
In this chapter, you will get a brief overview of the features of Power Pivot, which are
illustrated in detail later.
Load data into Excel and then create a Power Pivot Data Model.
Load data directly into Power Pivot Data Model.
The second way is more efficient because of the efficient way Power Pivot handles the data in
memory.
For more details, refer to chapter – Loading Data into Power Pivot.
You need not have the data in Excel tables when you are importing data from external sources.
If you have data as Excel tables in the workbook, you can add them to Data Model, creating
data tables in Data Model that are linked to the Excel tables.
When you create a PivotTable or PivotChart from Power Pivot window, they are created in the
Excel window. However, the data is still managed from Data Model.
You can always switch between the Excel window and Power Pivot window anytime, easily.
Data Model
The Data Model is the most powerful feature of Power Pivot. The data that is obtained from
various data sources is maintained in Data Model as data tables. You can create relationships
12
Excel Power Pivot
between the data tables so that you can combine the data in the tables for analysis and
reporting.
You will learn in detail about the Data Model in the chapter – Understanding Data Model
(Power Pivot Database).
Memory Optimization
Power Pivot Data Model uses xVelocity storage, which is highly compressed when data is
loaded into memory that makes it possible to store hundreds of millions of rows in memory.
Thus, if you load data directly into Data Model, you will be doing it in the efficient highly
compressed form.
Power PivotTables
You can create the Power PivotTables from Power Pivot window. The PivotTables so created
are based on the data tables in the Data Model, making it possible to combine data from the
related tables for analysis and reporting.
Power PivotCharts
You can create the Power PivotCharts from Power Pivot window. The PivotCharts so created
are based on the data tables in the Data Model, making it possible to combine data from the
related tables for analysis and reporting. The Power PivotCharts have all the features of Excel
PivotCharts and many more such as field buttons.
You can also have combinations of Power PivotTable and Power PivotChart.
DAX Language
The strength of Power Pivot comes from the DAX Language that can be used effectively on
the Data Model to perform calculations on the data in the data tables. You can have Calculated
Columns and Calculated Fields defined by DAX that can be used in the Power PivotTables and
Power PivotCharts.
13
4. Power Pivot – Loading Data Excel Power Pivot
If you want the data for Power Pivot, do it the second way, without Excel even knowing about
it. This is because you will be loading the data only once, in highly compressed format. To
understand the magnitude of difference, suppose you load data into Excel by first adding it to
the Data Model, the file size is say 10 MB.
If you load data into PowerPivot, and hence into Data Model skipping the extra step of Excel,
your file size could be as less as 1 MB only.
14
Excel Power Pivot
The PowerPivot window opens. Now you have two windows – the Excel workbook window and
the PowerPivot for Excel window that is connected to your workbook.
15
Excel Power Pivot
Click the Next > button. The Table Import Wizard displays the options for choosing how to
import data.
16
Excel Power Pivot
Click Select from a list of tables and views to choose the data to import.
17
Excel Power Pivot
Click the Next > button. The Table Import Wizard displays the tables and views in the Access
database that you have selected.
As you can observe, you can select the tables by checking the boxes, preview and filter the
tables before adding to Pivot Table and/or select the related tables.
18
Excel Power Pivot
As you can see, you can select specific columns by checking the boxes in the column labels,
filter the columns by clicking the dropdown arrow in the column label to select the values to
be included.
Click OK.
Click the Select Related Tables button.
Power Pivot checks what other tables are related to the selected Medals table, if a
relation exists.
19
Excel Power Pivot
You can see that Power Pivot found that the table Disciplines are related to the table Medals
and selected it. Click Finish.
Table Import Wizard displays – Importing and shows the status of the import. This will take
a few minutes and you can stop the import by clicking the Stop Import button.
20
Excel Power Pivot
Once the data is imported, the Table Import Wizard displays – Success and shows the results
of the import as shown in the screenshot below. Click Close.
21
Excel Power Pivot
You can scroll through the records (rows of the table) using the Record arrows below the
tabs.
Note that the Table Import Wizard options change as per the data source that is selected to
connect to. You might want to know what data sources you can choose from.
22
Excel Power Pivot
23