Thanks to visit codestin.com
Credit goes to www.scribd.com

0% found this document useful (0 votes)
130 views7 pages

Power Bi Notes

The document provides comprehensive notes on Power BI, covering data preparation, modeling, visualization, and asset deployment. Key topics include DAX and M languages, dataflows, relationships, visualizations, licensing, and security features. It also highlights best practices for data management and performance optimization within Power BI.
Copyright
© © All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as DOCX, PDF, TXT or read online on Scribd
0% found this document useful (0 votes)
130 views7 pages

Power Bi Notes

The document provides comprehensive notes on Power BI, covering data preparation, modeling, visualization, and asset deployment. Key topics include DAX and M languages, dataflows, relationships, visualizations, licensing, and security features. It also highlights best practices for data management and performance optimization within Power BI.
Copyright
© © All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as DOCX, PDF, TXT or read online on Scribd
You are on page 1/ 7

POWER BI NOTES

1. PREPARE THE DATA (15-20%)


- DAX language: analytical language for queries.
o Date functions:
 FORMAT(Date[date], "MMMM YYYY") -> “January 2022”
o CALCULATE: calculate something (you can override context).
 When used in row context, context transition is automatic.
o CALCULATETABLE: requires a table and outputs a table.
o IGNORE: you can ignore BLANK/NULL values, for example.
o FILTER: sub table
 ‘orders’[district] = ‘A1’ equals
 filter(all(‘orders’[district]), ‘orders’[district] = ‘A1’)
o SUMX (X-function): sum of expression evaluated for each row in a table.
 (Table, measure) to apply row-context.
 SUM: accepts only a column, not a measure.
o ALL: ignore any filters applied.
o CALENDARAUTO: returns a range of dates based on a dataset.
o CALENDAR: the same but requires the date limits.
o DATE: returns a timestamp.
o DATEDIFF: returns an interval between two dates.
o PATH: used for flattening.
o USERPRINCIPALNAME: [email protected] from Microsoft Entra ID login.
o DATESINPERIOD (, 7, DAY): takes the current and the next 7 days.
o DATEADD (): equal to MariaDB.
o LASTDATE (): returns the last value of a specified period (blank if the value is not found in
the table).
o ISEMPTY (): check whether a table is empty.
o ISBLANK (): check whether a value is blank.
o BLANK (): returns an empty value.
o VALUES (): it artificially creates a table.
o PATH (): concatenate the values of a hierarchy from the top level.
o PATHLENGTH: nº of items in the hierarchy.
o PATHITEM: returns the nth item from the top level (CEO).
o PATHITEMREVERSE: returns the nth item from the specified employee level.
o Total Sales YTD = TOTALYTD ([Total Sales], 'Date'[Date])
o AVERAGE: sum divided by non-null values (may be a problem).
- M language: ETL language used in Power Query.
o it’s zero-based.
o Two main blocks: let & in.
o #duration – specify datetime values to enter them into individual rows in a date table.
o #date – creates a date value based on the parameters.
o List.Combine() – combines multiple lists.
o List.Durations – returns list of count duration values.
o Table.ReplaceValue (table_name, old_value, new_value, replacer_function,
columns_list)
- The * represents the same as % in SQL.
- Combine Monthly dates and Dates: Calculated DAX column yyyymmdd in Monthly date table.
- Filter the data as early as possible: use WHERE clause in SQL statements when retrieving data.
- Unique values: values that appear only once in the dataset.
- Power Query Editor:
o Formula Bar: edit one step.
o Advanced Editor: edit multiple steps with M code.
o Data profiling tools:
 It requires Power Query. End users won’t see it. Use Table.Profile ()
function.
 Column quality: Valid, Error, Empty, Unknown and Unexpected Error.

 Column distribution: distinct (includes nulls), unique values and column chart.

 Column profile: more in-depth.


 Absolute number of empty values, Filter, Group by and Copy.

o Data Source Settings:


 Modify file path.
 Edit permissions.
 Query folding: perform M transformations on the data source and bring only
necessary data.
 Not supported for Excel, csv or flat files.
 View Native Query shows the query executed in the DB (if possible).
o Use DB query profiler or Query Diagnostics to determine
whether query folding is being used or not.
o Query Diagnostics:
 Diagnose step.
- Data view: access data within a dataset.
- Incremental refresh of a dataset:
o Define filter parameters.
 Define an incremental refresh policy.
 Publish the dataset.
o Requires:
 Query folding.
 Date field.
 RangeStart and RangeEnd parameters.
- Calculated table: only duplicates data.
- Text to number: row with ‘Error’ if the cast doesn’t work.
- Pivot: get confusion matrix -> unpivot: the opposite.
- Parameters: use one to switch from development to production environment.
- Split column: you can do it into columns or into rows.
- Unstructured data:
o Flatten out a JSON array of objects:
 Convert the List of records to a table.
o Expand [column] to New Columns/Rows requires a List.
- Dataflows: ETL that helps to build standardized tables for your organization, i.e., to save Power
Query transformations.
- If you have a lot of redundant data, consider creating shared datasets to avoid overloading a
data mart.
- Data sources:
o App developed with Microsoft Power Apps: Dataverse connector.
o SharePoint folder: use filter by folder path to select files.

2. MODEL THE DATA (30-35%)


- Iterator functions: they evaluate an expression based on row level.
- Date table:
o Auto Date/Time:
 It is only suggested for ad-hoc analysis and simple models.
 Disable global/current file Auto Date/Time option to avoid hidden tables.
 Fixed hierarchies and periods.
o Minimize model size. The dimension avoids data redundancy.
o Remove filter context if there is a relationship between date columns (in fact and
dimension tables). If the relationship is between date keys, you need to set the Date
dimension as date table.
- Display folder (folders in a table):
o Columns, calculated columns and measures can be assigned to it.
- Quick measures: apply calculations to fields.
- Measures (Data View or Report View):
o Implicit: created automatically when dragging a field into the Values of a visualization.
You can change the aggregation type.
o Explicit: created with DAX calculations. More flexible.
- Variables:
o Improve readability and performance (they cache the calculation).
o They are used for DAX formulas.
- Blank column might indicate that the data type is wrong (CAST required).
- Performance analyzer:
o Other may indicate waiting time between visuals.
- Rolling average: average considering all the data of the period until the point where we are.
- Relationships:
o One to one only allows both filter direction.
o Use CROSSFILTER function in measures to avoid setting up Both filter direction in the
relationship.
o Active vs. inactive relationships:
 Inactive relationships are only suitable for specific measures that won’t be used
for filtering at the same time as the filters of the active relationship.
- Hierarchies:
o Model hierarchies.
 Require data in the same table.
o Visual hierarchies.

3. VISUALIZE AND ANALYZE THE DATA (25-30%)


- Sync slicers:
o Copy paste slicer to a new page and select “Sync slicers”.
o Active the Sync slicers pane in the view ribbon and set it up there.
o When you sync a slicer from one page to another, PBI automatically places it in the new
page hidden.
- Edit interactions:
o Highlight.
- Bookmarks:
o Data option to capture specific filter state of a slicer visual.
o Current Page option to navigate back to the page of capture.
o Display option updates visibility state on the report page.
- Visualize data over time: Line charts.
- Custom visuals:
o R must be installed on the computer.
 2MB of visual output limit.
 No more than 5 minutes for each calculation.
 No more than 150 000 rows for each plot.
o Python is not required on the computer.
- Special visuals:
o Ribbon chart.
o Funnel (embudo).
o Clustered column chart: add avg, min, max, median and percentile reference lines.
o Web content tile: paste or type HTML content (dashboards).
o Video tile: post a single video (dashboards).
o Box % Whisker chart.
o Waterfall chart: running totals.
o Decomposition tree: analyze data from values in other fields.
 You can drill down into various fields.
 Useful for exploratory analysis.
o Table or matrix:
 Data bars (‘show bar only’ to avoid showing the actual values).
o KPI visual.

- Dashboards: “at-a-glance” perspective.


o Individual filters and slicers cannot be pinned.
o Allow you to combine multiple datasets.
- Themes use JSON file format.
- Conditional formatting: matrix and table visuals.
- Format Pane:
o Page information:
 Type drillthrough. (Keep all filters)
o Actions: back, bookmark, drill through, page navigation, Q&A, web URL, apply or clear
slicers.
- Anomaly detection:
o Line chart.
o Time series X-axis.
o No legends or multiple values.
- Tooltip: default or report page (customized) types.
- Create groups from a field (right click over the field):
o Bins: numerical and date fields.
 Size of bins.
 Number of bins.
o List: text fields.
- Create small multiples: select a dimension and display visual side-by-side.
- Mobile layout: in a dashboard you can edit both web and mobile layout.
- Categorize geographic fields: from mobile apps you will get the option of filter based on the
location.
- Tile theme:
o When pinning a tile to a dashboard, you can choose whether to maintain the report
theme or to select the dashboard theme instead.
o Dashboard theme only configurable in Power BI service and report theme in Power BI
Desktop.

4. DEPLOY AND MAINTAIN ASSETS (10-15%)


- License mode:
o Power BI free. NO collaboration.
o Power BI Pro:
 Up to 8 refreshes per day.
 9.99$ per user/month.
o Power BI Premium:
 Up to 48 refreshes per day.
 4995$ per capacity/month. Useful for a company with a lot of users.
- Endorsement level: for reports, apps, datasets and dataflows. You can also make datasets visible.
o Certify:
 The content meets quality standards and is reliable, ready for use.
 Admins decide who can certify content.
o Promote:
 Content ready to be distributed with your coworkers.
 Only write permission needed.
- Roles:
o Create a role: model view or report view.

Admin Member Contributor Viewer


Update, delete de workspace.
Manage workspace settings.
Add Members (or lower)
Publish, unpublish, change permissions in apps
Update apps
Publish, create, edit, delete content.
Schedule data refreshes (gateway)
View and interact with an item

- Row – level security (RLS):


o Steps:
 Set up roles in Power BI Desktop opening Manage roles.
 Create filters to define how the role filters the data (DAX expression filter).
 Add users to groups in Power BI Service.
o Only restricts data access to users with Viewer permissions.
o By default, filters in a single direction (check ‘Apply security filter in both directions’).
- Sensitivity labels:
o Users will have to log in before opening the report (even if it’s exported).
- Manage large number of users:
o Create Active Directory security groups (update membership to change a user’s group).
- Data alerts:
o Allowed visuals:
 KPIs.
 Gauges.
 Cards.
o Notification Center or email.
o Available for Power BI service and mobile app.
o Creation requirements:
 Dashboard in Premium capacity.
 User with Pro or Premium Per User (PPU) license.
o Alerts are individual.
- Storage mode (set it up in model view):
o Dual:
 Optimize both Import and DirectQuery queries.
 It caches table data and let Power BI decide the best way to query.
o Import: holds full support for Q&A and Quick Insights.
o DirectQuery:
 Query reduction setting to disable cross highlighting and filtering of visuals
within the same report.
 Does not work with time intelligence DAX functions because they have
performance implications.
- DAX Studio: connect it to the data model.
o Clear Cache function to clear the data engine cache.
 Clear the visual cache adding a blank page to the file.
o Refresh Metadata function.
- Report page load time affected by number of visuals and DAX performance (number of rows).
- Workspace:
o Notification sent to any added user.
o Apps:
 Can be installed automatically for any user, without requiring notifications.
o Deployment pipelines: move artifact between test, development and production.
o Metrics: to create goals based on existing datasets.
- Workspace OneDrive: allows you to configure a Microsoft 365 group whose SharePoint Online
document library is available to workspace users.
- Power BI Report Builder:
o Create “pixel-perfect” reports in PDF format with a lot of pages, for example.
- AI features:
o Q&A: to add a new visual to a dashboard that is not present in a report in the
workspace.
o Key influencers: they consider the number of data points for the category.
o Anomaly detection.
o Decomposition tree.
o Sentiment analysis.
o Forecasting with AI.
o Image tagging.
- Power BI report server:
o Use Power BI optimized for Report Server. This is a version of Power BI Desktop.

You might also like