Advanced Tips And Tricks For Power Query

Slides:



Advertisements
Similar presentations
The State of SharePoint BI
Advertisements

Les Webcasts Groupe des Utilisateurs SQL Server Septembre 2013 – Power Query Chris Webb – Technitrain MVP SQL Server.
Chris Webb Crossjoin Consulting Ltd
Cache –Warming Strategies for Analysis Services 2008 Chris Webb Crossjoin Consulting Limited
Leveraging BI in SharePoint with PowerPivot and Power View
Arjun Krishnamoorthi  Power View enables self-service BI by providing simple to use ad-hoc reporting for business users and decision.
Implementing Business Analytics with MDX Chris Webb London September 29th.
Matt Masson| Senior Program Manager
Chapter 7 Managing Data Sources. ASP.NET 2.0, Third Edition2.
Bar|Scan ® Asset Inventory System The leader in asset and inventory management.
SQL Reporting Services Overview SSRS includes all the development and management pieces necessary to publish end user reports in  HTML  PDF 
Microsoft Office SharePoint Server Business Intelligence Tom Rizzo Director, Microsoft Office SharePoint Server
Building a Data Warehouse with SQL Server Presented by John Sterrett.
Data Analysis Nirvana: Excel 2013 Business Intelligence Features Tom Jones – President, Iridium Technology LLC.
Realizing Business Insights with PowerPivot
Performance Tuning Cubes and Queries in Analysis Services 2008 Chris Webb
Common Analysis Services Multidimensional Design Mistakes and How to Avoid Them Chris Webb
Self Guided Tour for Query V8.4 Basic Features. 2 This Self Guided Tour is meant as a review only for Query V8.4 Basic Features and not as a substitute.
Virtual techdays INDIA │ November 2010 PowerPivot for Excel 2010 and SharePoint 2010 Joy Rathnayake │ MVP.
Introducing Reporting Services for SQL Server 2005.
M1G Introduction to Database Development 6. Building Applications.
Winrunner Usage - Best Practices S.A.Christopher.
Fun with Scoped Assignments
HDNUG 27-March-2007 SQL Server 2005 Suite as a Business Intelligence Solution.
Data Management Console Synonym Editor
David Dye.  Introduction  Introduction to PowerPivot  Working With PowerPivot.
BI Terminologies.
R7 Integrator and Enterprise Integrator: You won’t believe this is XA… Deborah Vermillion, VP Consulting Services, CPIM, CIRM Belinda Daub, Senior Consultant.
Building Dashboards SharePoint and Business Intelligence.
IBM DB2 Web Query for System i. DB2 Web Query for System i Open Windows Internet Explorer, type in the address bar the following with your system name.
Highline Class, BI 348 Basic Business Analytics using Excel Introduction to PowerPivot 1.
DEV14 – Building Business Dashboards: Excel Services, KPIs and Report Centers Darwin Schweitzer Enterprise Technology Strategist
Power BI V2.0: Is It Any Good?
Jamie Oliver Knives Promotion
CPSC 203 Introduction to Computers T97 By Jie (Jeff) Gao.
SharePoint 2013 BI Features & Options Introduction Brad Wilcox Site:
Intro to Power BI Azhagappan Arunachalam.  Senior Database Architect   PowerBICentral.com  (blog on getting started.
SharePoint 2007 Business Intelligence October 23 th, 2008 Neil Iversen - Inetium.
Delivering KPIs With Analysis Services Peter Myers Mentor SolidQ.
BISM Introduction Marco Russo
Introduction to the Power BI Platform Presented by Ted Pattison.
Advanced MDX Tips And Tricks Chris Webb. Who Am I? Chris Webb UK-based consultant and trainer:
Power View Overview April 25, POWER VIEW Presentation ready visualizations for the masses.
Excel Services Displays all or parts of interactive Excel worksheets in the browser –Excel “publish” feature with optional parameters defined in worksheet.
Write DAX Queries using DAX Studio Alex Barbeau
A highway through the mountains of data with the SQL Server Tabular Model This presentation is a walk through in-memory database and reporting features.
Or How I Learned to Love the Cube…. Alexander P. Nykolaiszyn BLOG:
MAKING BUSINESS INTELLIGENT Brought to you by your local PASS Community! Self Service ETL with Power Query Welcome.
Advanced Analysis Services Security Chris Webb Crossjoin Consulting Limited.
Agenda Integration points between Excel and Power BI How can I decide between the two technologies Do I need to chose? Q&A.
EQuIS and Tableau Getting the most out of your tools.
Microsoft PowerBI – Advanced Solutions with Microsoft Excel and PowerBI Presented by: Phillip Guglielmi, CPA | Senior BI Consultant and Solutions Architect.
Power BI Performance Tips & Tricks
6/19/2018 © 2014 Microsoft Corporation. All rights reserved. Microsoft, Windows, and other product names are or may be registered trademarks and/or trademarks.
Leveraging BI in SharePoint with PowerPivot and Power View
Solving the Hard Problems
Introduction to tabular models
Budgeting with Power Pivot
Introduction to tabular models
Data Integration with Power Query
Linda Nguyen, John Swinehart, Yiwen (Cathy) Sun, Nargiza Nosirova
DAX and the tabular model
TechEd /24/2018 6:19 AM © 2013 Microsoft Corporation. All rights reserved. Microsoft, Windows, and other product names are or may be registered.
What query folding means to self-service BI projects
Building your First Cube with SSAS
Introduction to Access
Introduction to Dataflows in Power BI
Playing with (M)agic: Introduction to Writing M Code in Power BI
A lightweight editor for SSAS Tabular Models built in .NET / WinForms
Making your M Queries Dynamic in Power BI
Presentation transcript:

Advanced Tips And Tricks For Power Query Chris Webb chris@crossjoin.co.uk @technitrain

Who Am I? Chris Webb UK-based consultant and trainer: chris@crossjoin.co.uk Twitter @Technitrain UK-based consultant and trainer: www.crossjoin.co.uk www.technitrain.com Author of several books: MDX Solutions Expert Cube Development with SSAS 2008 Analysis Services 2012: The BISM Tabular Model Power Query for Power BI and Excel SQL Server MVP Blogger: http://blog.crossjoin.co.uk/

Agenda Power Query recap Introduction to M Parameterised queries Privacy levels and the Formula Firewall Query folding and performance Creating and using M functions Combining data from multiple data sources

Power Query Recap Power Query is a self-service data manipulation tool Excel add-in for Excel 2010/2013 Native feature of Excel 2016 as “Get & Transform” The “Get Data” part of Power BI Desktop Integrated with SSIS, SSRS and SSAS at some point? It does three things: Connects to multiple data sources Applies transformations to that data Loads data to Excel tables and/or the Data Model New builds of Power Query released almost every month

M Power Query is actually a UI on a language (unofficially) called M M is a functional language like F# Nothing like Excel formula language, DAX or VBA  Everything you do in the UI is translated to M The M code is visible in the Formula Bar You can edit the whole M script for a query in the Advanced Editor Understanding how to write M is the key to writing more complex transformations and calculations

Values and Expressions Expressions are central to the M language Expressions can be calculated to return Values 1+1 is an expression 1+1 returns the value 2 Values can be: Primitives like numbers or text Tables, lists, records, functions… Each Power Query query is a single expression that returns a single value

Let Expressions Each Power Query query created by the user interface consists of a single Let expression Let expressions contain a series of named expressions that can reference other named expressions These become the steps in a query The Let expression finishes with an In, where the final value of the expression is calculated This is the output of the query It can reference any of the named expressions

Parameterised Queries For large data sources, users should be prevented from downloading all data to Excel Takes too long May crash Excel Therefore you need to give users an easy way to select the data they want to download This involves Giving them an easy-to-use UI Writing M code to handle the parameterization

Parameterised Queries Power Query queries can reference other Power Query queries Therefore you can use Power Query to load data on what to filter by from an Excel table or named range …and pass that data as a parameter to a second Power Query query to load the main data set

Query Folding Fast data load performance is very important for users For certain data sources (relational databases , OData and a few others) Power Query can push logic back to the data source Eg translate your Power Query transformations to SQL This is called Query Folding and can make a massive difference to performance

Query Folding There is no indication in the UI that Query Folding is happening You need to use tools like SQL Server Profiler Certain operations prevent folding, such as using native SQL queries A query may be partially folded – reordering steps can increase the amount that is folded

Privacy Levels And The Formula Firewall Power Query cares about data privacy! Sending data from one source as parameter values to another source could be dangerous Power Query will prompt you to set data privacy levels to govern whether this can happen Turning on ‘Fast Combine’ stops Power Query from checking this But this will need to be turned on every time the workbook is opened on a new PC

M Functions Functions are expressions that take parameters to return a value The Standard Library contains all of the built-in functions You can define your own functions in the Advanced Editor They can then be invoked in Within the query you’re writing Other queries in the same workbook Functions are a great way of: Sharing logic between queries Separating complex logic from otherwise simple queries Controlling how end-users access data sources

Functions For Data Access M functions can be an alternative to parameterised queries Use M functions when an end user needs to create multiple queries against the same data source to get different slices of data With more advanced M code you can provide: Default values for parameters A list of available values that can be selected from a dropdown box

Combining Data From Multiple Sources Power Query makes it easy to combine data from multiple, identically structured csv files However end users often need to do the same thing with other data sources, for example Excel files The solution is to create an M function to do this

Thanks!