Book Image

Hands-On Business Intelligence with DAX

By : Ian Horne
Book Image

Hands-On Business Intelligence with DAX

By: Ian Horne

Overview of this book

Data Analysis Expressions (DAX) is known for its ability to increase efficiency by extracting new information from data that is already present in your model. With this book, you’ll learn to use DAX’s functionality and flexibility in the BI and data analytics domains. You’ll start by learning the basics of DAX, along with understanding the importance of good data models, and how to write efficient DAX formulas by using variables and formatting styles. You’ll then explore how DAX queries work with the help of examples. The book will guide you through optimizing the BI workflow by writing powerful DAX queries. Next, you’ll learn to manipulate and load data of varying complexity within Microsoft products such as Power BI, SQL Server, and Excel Power Pivot. You’ll then discover how to build and extend your data models to gain additional insights, before covering progressive DAX syntax and functions to understand complex relationships in DAX. Later, you’ll focus on important DAX functions, specifically those related to tables, date and time, filtering, and statistics. Finally, you’ll delve into advanced topics such as how the formula and storage engines work to optimize queries. By the end of this book, you’ll have gained hands-on experience in employing DAX to enhance your data models by extracting new information and gaining deeper insights.
Table of Contents (18 chapters)
1
Section 1: Introduction to DAX for the BI Pro
7
Section 2: Understanding DAX Functions and Syntax
14
Section 3: Taking DAX to the Next Level

What this book covers

Chapter 1, What is DAX?, gives you an overview of the DAX language, what it is, and how, as a BI pro, you can use it to create new information from existing data. It will introduce the different calculation types, calculated columns and measures, and the CALCULATE function, probably the most important DAX function.

Chapter 2, Using DAX Variables and Formatting, teaches you about using variables in DAX formulas and how these can make your DAX code easier to read and potentially more efficient. You will also look at recommended formatting styles for DAX code. Finally, you'll look at error handling and how using variables can make this easier.

Chapter 3, Building Data Models, talks about the importance of building a well-defined data model, both from the point of view of a BI professional and in terms of making DAX easier to use.

Chapter 4, Working with DAX in Excel, Power BI, and SSAS, looks at the three different platforms that support DAX – Excel, Power BI, and SSAS Tabular. You will look at loading data in more depth and the different ways DAX is used in each.

Chapter 5, Getting it into Context, moves beyond the basics and builds upon what you learned about evaluation contexts in the first chapter. You will learn about the difference between the row context and the filter context and how these affect DAX functions. You will also take a more in-depth look at the CALCULATE function.

Chapter 6, Progressive DAX Syntax and Functions, explores the structure of DAX syntax, and you'll look at the groups of functions currently available in DAX. You'll take a more in-depth look at relationships, aggregation functions, and parent-child functions, all with hands-on examples.

Chapter 7, Table Functions, concerns the DAX table functions and includes details of the syntax of each function, as well as an explanation of how each works. Finally, you'll get hands-on with some practical examples of the functions being used.

Chapter 8, Date, Time, and Time Intelligence Functions, is where you will learn about the DAX date, time, and time intelligence functions, with details of the syntax of each function, including an explanation of how each works. Finally, you'll get hands-on with some practical examples of the functions being used.

Chapter 9, Filter Functions, moves on to the DAX filter functions, with details of the syntax of each function, including an explanation of how each works. Finally, you'll get hands-on with some practical examples of the functions being used.

Chapter 10, Statistical Functions, covers the DAX statistical functions, with details of the syntax of each function, including an explanation of how each works. Finally, you'll get hands-on with some practical examples of the functions being used.

Chapter 11, Working with DAX Patterns, is the final chapter of part 2, and you will look at some examples of DAX being used in the form of DAX patterns. Each pattern will have a walkthrough involving a practical example that breaks down the code and gives a detailed explanation of how it works.

Chapter 12, Optimizing Your Data Model, delves into the VertiPaq engine and how it can be used to help you optimize your data model. You'll also look at some ways in which you can optimize your data model along with how and why this may improve performance.

Chapter 13, Optimizing Your DAX Queries, shows you some techniques that will help to make your DAX calculations more efficient, including a look at some tools to help you analyze query performance. You'll also look at the two DAX calculation engines: the storage engine and the formula engine.