Overview
Power BI is Microsoft's business intelligence platform that enables you to connect to hundreds of data sources, transform raw data into meaningful insights, and share interactive dashboards across your organization — all without writing complex code. It is used by analysts, managers, and executives worldwide to make data-driven decisions.
Power BI turns scattered spreadsheets and database tables into visual stories. A sales manager in Chennai can see live revenue by region; a CFO can monitor expenses against budget — all in one screen, updated automatically.
Key Benefits
- No-code data transformation — Clean and shape data visually using Power Query without writing SQL.
- Live dashboards — Connect to databases, Excel files, cloud services and see data refresh automatically.
- Rich visualizations — 30+ built-in chart types plus hundreds of custom visuals from AppSource.
- Enterprise sharing — Publish reports to Power BI Service and share with your team via a browser link.
- Mobile-ready — Reports automatically adapt to the Power BI mobile app on Android and iOS.
- Cost-effective — Power BI Desktop is free; Power BI Pro is Rs. 750/user/month; Premium for large orgs.
Real-World Example
A Chennai-based manufacturing company uses Power BI to connect its ERP (SAP), Excel production logs, and SQL warehouse data into a single dashboard. Operations head views daily output vs target, quality defects by shift, and inventory levels — all updated every morning at 8 AM automatically.
📝 Quick Check
Test your understanding of this chapter
Q1. Which Microsoft product ecosystem is Power BI part of?
Q2. What can Power BI connect to?
Q3. Who primarily uses Power BI?
Answer all 3 questions above to mark this chapter complete.
Three Core Components
- Power BI Desktop — Free Windows application where you build reports. Connect data, transform it in Power Query, write DAX measures, and create visuals.
- Power BI Service (app.powerbi.com) — Cloud-based portal to publish, share, and collaborate on reports. Supports dashboards, workspaces, and scheduled refresh.
- Power BI Mobile — Android/iOS app to view and annotate reports on the go. Supports push notifications for data alerts.
Supporting Tools in the Ecosystem
- Power Query — ETL (Extract, Transform, Load) engine built into Desktop and Excel. Uses M language.
- DAX (Data Analysis Expressions) — Formula language for creating measures and calculated columns.
- Power BI Gateway — Software installed on-premises to bridge your local SQL Server or Excel files with the Power BI cloud service for scheduled refresh.
- Dataflows — Reusable Power Query transformations stored in the cloud, shared across multiple reports.
- Datasets / Semantic Models — The data model (tables + relationships + measures) published to the Service, reusable by multiple reports.
- Power BI Embedded — Embed Power BI reports into your own website or application using APIs.
Typical Workflow
| Step | Tool | Action |
|---|---|---|
| 1. Connect | Power BI Desktop | Connect to SQL Server / Excel / API |
| 2. Transform | Power Query | Clean columns, remove blanks, merge tables |
| 3. Model | Model View | Create relationships, date tables, measures |
| 4. Visualize | Report View | Build bar charts, KPI cards, maps |
| 5. Publish | Power BI Service | Share with team, set up refresh |
📝 Quick Check
Test your understanding of this chapter
Q1. What is Power BI Desktop primarily used for?
Q2. Which component publishes and shares reports in the cloud?
Q3. Power BI Mobile app is available on:
Answer all 3 questions above to mark this chapter complete.
System Requirements
- Operating System: Windows 8.1 / Windows 10 / Windows 11 (64-bit recommended)
- RAM: Minimum 2 GB; Recommended 4 GB or more for large datasets
- Disk Space: 2 GB free for installation
- Display: 1440 x 900 resolution or higher recommended
- .NET Framework: 4.6.2 or higher (auto-installed)
Installation Steps
- Option 1 (Recommended): Install from Microsoft Store — search "Power BI Desktop" and click Install. Auto-updates monthly.
- Option 2: Download .exe from powerbi.microsoft.com/downloads. Run installer, accept license, choose install path.
- Sign in: Launch Power BI Desktop. Sign in with your Microsoft/Office 365 account (free to create at microsoft.com).
- Updates: Power BI Desktop updates every month (e.g., September 2026 release). Check Help > About for your current version.
First Launch Checklist
- Home ribbon visible with Get Data, Transform Data, and Visualizations pane on right
- Three view icons on the left: Report (bar chart icon), Data (table icon), Model (diagram icon)
- Sign-in account displayed top-right corner
- Sample report option in splash screen — click to open a pre-built sales demo
📝 Quick Check
Test your understanding of this chapter
Q1. What is the first step in the Power BI workflow?
Q2. After transforming data in Power Query, the next step is:
Q3. Dashboards in Power BI Service are:
Answer all 3 questions above to mark this chapter complete.
Report View Layout
- Ribbon (Top): Home, Insert, Modeling, View, Optimize, Help tabs — tools for inserting visuals, formatting, and publishing.
- Canvas (Center): The blank report page where you drag visuals. Each page is a tab at the bottom.
- Visualizations Pane (Right): Pick a chart type. Below it: Fields, Format, Analytics sub-panes.
- Fields Pane (Far Right): Lists all tables and columns from your data model. Drag fields onto the canvas or into visual buckets.
- Filters Pane: Apply page-level or visual-level filters without adding a slicer visual.
🎯 Power BI Desktop — Ribbon Tabs Reference
The ribbon at the top of Power BI Desktop is your command center. Below is a complete breakdown of every tab and what each option does — with actual screenshots from the software.
| Menu / Button | What It Does |
|---|---|
| Get Data | Connect to 100+ data sources — Excel, SQL, web, SharePoint, cloud services and more. The starting point for every report. |
| Excel Workbook | Quick shortcut to import data directly from a local Excel (.xlsx / .xls) file. |
| OneLake Catalog | Browse and connect to datasets stored in Microsoft Fabric's OneLake data lake platform. |
| SQL Server | Direct connector to Microsoft SQL Server databases — enter server name and credentials to pull tables or write custom SQL. |
| Enter Data | Manually type a small table of data inside Power BI — useful for lookup tables, parameters, or sample data without a file. |
| Dataverse | Connect to Microsoft Dataverse (used by Power Apps) to pull business data stored in the Power Platform. |
| Recent Sources | Quickly reconnect to data sources you've used before — saves time re-entering connection details. |
| Transform Data | Opens Power Query Editor — the ETL (Extract, Transform, Load) workspace where you clean, shape, and reshape your data before loading. |
| Refresh | Re-runs all data queries and refreshes every table in your report with the latest data from the source. |
| New Visual | Adds a blank visual placeholder on the canvas — then select a chart type from the Visualizations pane. |
| Text Box | Insert a free-form text box on the canvas — for titles, annotations, descriptions, or instructions. |
| More Visuals | Browse and import custom visuals from the AppSource marketplace — charts not included by default (e.g. Gantt, Sankey). |
| New Visual Calculation | Write a DAX expression that calculates a value directly at the visual level — no new measure or column needed in the model. |
| New Measure | Create a DAX measure — a calculated formula (SUM, AVERAGE, IF, etc.) stored in the model and usable across any visual. |
| Quick Measure | Generate common DAX patterns (year-over-year change, running total, average per category) using a guided wizard — no DAX writing needed. |
| Sensitivity | Apply Microsoft Information Protection (MIP) sensitivity labels (Confidential, Public, Internal) to classify and protect your report. |
| Publish | Upload your .pbix file to Power BI Service (web) — makes the report accessible online and enables sharing, scheduling, and dashboards. |
| Prep Data for AI | Tag your semantic model so Copilot and Q&A features understand your data better — set synonyms, descriptions, and relationships. |
| Copilot | AI assistant inside Power BI — asks questions in plain English, generates visuals, writes DAX measures, and summarizes report pages. |
| Menu / Button | What It Does |
|---|---|
| New Page | Adds a blank report page (tab) to your report — useful for separating Executive Summary, Detail Views, and KPI pages. |
| New Visual | Same as in Home — inserts a visual placeholder and opens the Visualizations pane to pick a chart type. |
| More Visuals | Access AppSource marketplace for custom chart types — waterfall, bullet charts, word clouds, maps and hundreds more. |
| Key Influencers | AI visual — automatically analyzes your data to show which factors most influence a metric (e.g., what drives high sales). |
| Decomposition Tree | AI visual — interactive drill-down that breaks a metric into its components, letting users explore data paths manually or via AI splits. |
| Narrative / Smart Narrative | AI visual — auto-generates a written text summary of your data in plain language, updating dynamically when filters change. |
| Paginated Report | Insert a paginated report visual — ideal for pixel-perfect, print-ready reports (invoices, statements) rendered page by page. |
| Power Apps | Embed a Power Apps app inside your Power BI report — allows users to write back to data sources without leaving the dashboard. |
| Power Automate | Embed a Power Automate flow trigger button — run workflows (send emails, create records) directly from a report with one click. |
| Text Box | Add a free-form text annotation or label anywhere on the canvas — for context, headings, or explanatory notes. |
| Buttons | Add interactive buttons (Back, Blank, Bookmark, Drill-through, etc.) for report navigation and user actions. |
| Shapes | Insert geometric shapes (rectangles, lines, arrows, circles) — used for visual grouping, dividers, and layout design. |
| Image | Embed a static image file (logo, icon, background) from your computer onto the report canvas. |
| Add a Sparkline | Add a tiny inline trend line inside a table or matrix cell — shows movement over time without a full separate chart. |
| Menu / Button | What It Does |
|---|---|
| Manage Relationships | Open the relationship manager — view, create, edit, or delete links between tables. The most critical step in building your data model. |
| New Visual Calculation | Create a calculation scoped to a specific visual — doesn't affect the data model, just that one chart or table. |
| New Measure | Write a DAX formula (e.g., Total Sales = SUM(Sales[Amount])) stored in the model — reusable across all visuals and pages. |
| Quick Measure | Guided wizard to create common DAX patterns without writing code — running totals, percentages of total, time intelligence, etc. |
| New Column | Add a calculated column to a table using DAX — computed row by row, stored in the model (increases file size). |
| New Table | Create a calculated table using DAX — useful for calendar tables, parameter tables, or bridging tables. |
| Mark as Date Table | Tell Power BI which table is your date/calendar table — enables automatic time intelligence functions (TOTALYTD, SAMEPERIODLASTYEAR, etc.). |
| Change Detection | Set up automatic page refresh for real-time reports — Power BI checks the data source at intervals and updates only when data has changed. |
| New Parameter | Create a What-If parameter — a numeric slicer that dynamically changes a value in your DAX measures (e.g., discount %, growth rate). |
| Manage Roles | Define Row-Level Security (RLS) roles using DAX filter rules — restricts which rows of data each user or group can see. |
| View As | Test your RLS roles — preview the report as if you were a specific role to verify that data filtering works correctly before publishing. |
| Q&A Setup | Configure the natural language Q&A feature — add synonyms, mark fields as featured, and set how Power BI interprets your questions. |
| Language / Linguistic Schema | Download and edit the YAML linguistic schema file — add synonyms, phrasings, and domain-specific terms to improve Q&A accuracy. |
| Menu / Button | What It Does |
|---|---|
| Themes | Apply a pre-built colour and font theme to your entire report in one click — or import a custom JSON theme file for your brand colours. |
| Page View | Switch how the canvas fits the screen: Fit to Page, Fit to Width, or Actual Size — affects only your preview, not the published report. |
| Mobile Layout | Toggle to a phone-screen canvas and rearrange visuals specifically for mobile viewers — Power BI Service shows this layout on phones. |
| Scale to Fit | Automatically scale the report canvas to fill your available screen area — helpful on smaller monitors. |
| Gridlines | Show or hide alignment grid lines on the canvas — helps position and align visuals precisely. |
| Snap to Grid | When enabled, visuals automatically snap to the nearest grid point when you move or resize them — ensures clean alignment. |
| Lock Objects | Lock selected visuals in place so they can't be accidentally moved or resized — useful for background shapes and headers. |
| Filters | Show or hide the Filters pane on the right side of the canvas. |
| Bookmarks | Open the Bookmarks pane — capture the current state of the report (filters, visuals, page) as a named bookmark for navigation or storytelling. |
| Selection | Open the Selection pane — see all objects on the current page, change their visibility (eye icon), and manage z-order (layering). |
| Performance Analyzer | Record and measure how long each visual takes to load — identifies slow DAX queries or render bottlenecks in your report. |
| Sync Slicers | Open the Sync Slicers pane — make a slicer on one page control filters on other pages too, keeping context consistent across the report. |
| Menu / Button | What It Does |
|---|---|
| Pause Visuals | Temporarily stops all visuals from refreshing when you make changes — speeds up editing by preventing constant re-rendering while you work. |
| Refresh Visuals | Manually trigger a refresh of all paused visuals — use after Pause Visuals to apply your changes in one go. |
| Optimization Presets | Apply preset optimization profiles (e.g., "Balanced", "Performance") that adjust report settings like query reduction and render behavior. |
| Performance Analyzer | Same as View tab — record visual load times and DAX query durations to find and fix slow parts of your report. |
| Apply All Slicers | When using query reduction mode, slicers don't filter until you click "Apply" — this button applies all pending slicer selections at once. |
| Menu / Button | What It Does |
|---|---|
| About | Shows the Power BI Desktop version number and build — useful when reporting bugs or checking if you need an update. |
| Guided Learning | Opens Microsoft's guided learning paths for Power BI — structured courses for beginners to advanced users. |
| Training Videos | Links to official Microsoft video tutorials — short, task-based videos on specific Power BI features. |
| Documentation | Opens the official Power BI documentation (docs.microsoft.com) — full reference for every feature, DAX function, and connector. |
| Support Blog | Microsoft's Power BI support blog — troubleshooting guides, known issues, and workarounds published by the product team. |
| Power BI Blog | The official Power BI team blog — monthly updates, new feature announcements, and deep-dive articles on capabilities. |
| Community | Opens the Power BI Community forum — ask questions, find answers, and browse thousands of discussions from users worldwide. |
| Power BI for Developers | Resources for embedding Power BI into apps — REST API documentation, JavaScript SDK, and embedding tutorials. |
| Submit an Idea | Opens the Power BI Ideas portal — upvote existing feature requests or submit new ideas directly to the Microsoft product team. |
| External Tools | Launch third-party tools connected to Power BI Desktop (e.g., DAX Studio, Tabular Editor) — for advanced model editing and DAX debugging. |
| Examples | Download sample .pbix reports from Microsoft — pre-built dashboards like Retail Analysis, IT Spend, and Human Resources to study. |
| Consulting Services | Find certified Microsoft partners and consulting firms who specialize in Power BI implementations and training. |
ribbon_home.png, ribbon_insert.png, ribbon_modeling.png, ribbon_view.png, ribbon_optimize.png, ribbon_help.png and upload them to an images/ folder in your Hostinger File Manager alongside this page. The images will automatically appear above each table.
Three Main Views
- Report View: Build and format your visuals. The final dashboard the user sees.
- Data View (Table View): Browse your loaded tables row by row. Spot data quality issues. Write calculated columns here.
- Model View: See all tables as boxes with lines showing relationships between them. Essential for star schema design.
Key Shortcuts to Know
| Shortcut | Action |
|---|---|
| Ctrl + Z | Undo last action |
| Ctrl + S | Save .pbix file |
| Alt + F4 | Close Desktop |
| Ctrl + Click | Multi-select visuals on canvas |
| F5 | Refresh data (re-run queries) |
📝 Quick Check
Test your understanding of this chapter
Q1. Which edition of Power BI is free to download?
Q2. Power BI Pro is required for:
Q3. Power BI Premium capacity is billed:
Answer all 3 questions above to mark this chapter complete.
Categories of Data Sources
- File-based: Excel (.xlsx), CSV, JSON, XML, PDF tables, Power BI template (.pbit)
- Databases: SQL Server, MySQL, PostgreSQL, Oracle, SAP HANA, Snowflake, Azure SQL
- Cloud Services: SharePoint Online, OneDrive, Azure Blob Storage, Dynamics 365, Salesforce
- Online Services: Google Analytics, Facebook, Twilio, GitHub, MailChimp
- Other: Web (scrape HTML tables), OData feed, ODBC, R script, Python script
How to Access Get Data
- Click Home > Get Data to open the full connector gallery with 100+ options.
- Common sources appear as quick buttons: Excel, Text/CSV, SQL Server, Web.
- Search by typing in the search box at the top of the Get Data dialog (e.g., type "postgres" to find PostgreSQL connector).
- Each connector may require a driver or credentials — Power BI prompts you automatically.
Connectivity Modes
| Mode | Data Stored In | Best For |
|---|---|---|
| Import | Inside .pbix file | Small/medium datasets, fast performance |
| DirectQuery | Always in source DB | Large datasets, live data needs |
| Live Connection | Analysis Services or PBI Dataset | Enterprise, centralized models |
📝 Quick Check
Test your understanding of this chapter
Q1. Which connector imports Excel data into Power BI?
Q2. What does the 'Get Data' button do?
Q3. CSV files are imported using:
Answer all 3 questions above to mark this chapter complete.
Connecting to Excel
- Go to Home > Get Data > Excel Workbook. Browse to your .xlsx file.
- The Navigator dialog shows all sheets and named Tables inside the file. Select one or multiple.
- Best Practice: Format your Excel data as a Table (Ctrl+T) before connecting — Power BI recognizes Table names and handles new rows automatically on refresh.
- Avoid connecting to raw sheet ranges — if someone adds a column in Excel, it may break your query.
Connecting to CSV
- Go to Home > Get Data > Text/CSV. Power BI auto-detects delimiter (comma, semicolon, tab).
- Check the preview — if the first row is not a header, uncheck "Use first row as headers" in Power Query.
- CSV files do not have data types — Power BI guesses. Always verify column types in Power Query (numbers vs text).
Example: Sales Data Excel File
| Order ID | Product | Qty | Unit Price (Rs.) | Total (Rs.) |
|---|---|---|---|---|
| ORD-001 | Laptop | 2 | 45,000 | 90,000 |
| ORD-002 | Mouse | 10 | 850 | 8,500 |
| ORD-003 | Keyboard | 5 | 1,200 | 6,000 |
After connecting, Power BI imports this as a table. You can then create a measure: Total Sales = SUM(Sales[Total])
📝 Quick Check
Test your understanding of this chapter
Q1. Which authentication is used for SQL Server with Windows login?
Q2. What is DirectQuery mode?
Q3. Import mode copies data into:
Answer all 3 questions above to mark this chapter complete.
Steps to Connect
- Go to Home > Get Data > SQL Server.
- Enter Server name (e.g.,
DESKTOP-ABC\SQLEXPRESSor192.168.1.10) and optional Database name. - Choose Import or DirectQuery mode.
- Authentication: Windows Authentication (domain users) or SQL Server Authentication (username + password).
- The Navigator lists all databases, tables, and views. Select the tables you need.
Using a Native SQL Query
Instead of loading an entire table, you can write a SQL query to pull only the data you need:
SELECT
OrderID,
CustomerName,
OrderDate,
TotalAmount
FROM dbo.Orders
WHERE OrderDate >= '2025-01-01'
AND TotalAmount > 10000
This reduces the data loaded into Power BI, improving performance — especially important for tables with millions of rows.
Common Issues & Fixes
- Cannot connect: Check that SQL Server Browser service is running and port 1433 is open in firewall.
- Login failed: Use SQL Auth with the correct username/password. Windows Auth needs the machine to be on the same domain.
- Timeout: Add
CommandTimeoutoption in Advanced settings when connecting to slow servers.
📝 Quick Check
Test your understanding of this chapter
Q1. SharePoint Online data is connected using:
Q2. To connect Power BI to a REST API, you use:
Q3. Azure SQL Database connection requires:
Answer all 3 questions above to mark this chapter complete.
Web Connector (HTML Table Scraping)
- Go to Get Data > Web. Enter any public URL that contains HTML tables.
- Power BI scrapes all tables found on the page. Example: Wikipedia's list of Indian states by GDP.
- Power Query then lets you clean the scraped data (remove header rows, fix types).
- Web data refreshes on schedule — Power BI re-scrapes the URL at each refresh.
SharePoint Online Lists
- Go to Get Data > SharePoint Online List. Enter your SharePoint site URL (e.g.,
https://yourcompany.sharepoint.com/sites/Sales). - Sign in with your Microsoft 365 account. All lists from that site appear in the Navigator.
- SharePoint lists work great for team-maintained lookup tables (product catalog, employee list, project status).
- Tip: Avoid connecting to SharePoint Excel files via the File connector — use SharePoint Folder for proper refresh.
OneDrive for Business
- Connect to files stored in OneDrive using Get Data > Web with the file's shareable link (change
?e=xxxto?format=csvfor CSV). - Better approach: Use Get Data > SharePoint Folder and navigate to the OneDrive path.
📝 Quick Check
Test your understanding of this chapter
Q1. What does a Power BI Gateway do?
Q2. Which gateway mode supports multiple users?
Q3. Scheduled refresh requires what for on-premises data?
Answer all 3 questions above to mark this chapter complete.
Import Mode
- Data is copied from the source into the Power BI file (.pbix) in memory (VertiPaq engine).
- All DAX calculations run on the in-memory copy — extremely fast.
- Data is as fresh as your last refresh (scheduled or manual). Not real-time.
- File size limit: 1 GB for Pro, 100 GB for Premium per dataset.
DirectQuery Mode
- Data stays in the source database. Power BI sends SQL queries to the DB each time a visual is clicked.
- Always shows the latest data — truly real-time for live dashboards.
- Performance depends on your database server speed. Can be slow for complex DAX.
- Some DAX functions are not supported in DirectQuery (e.g., certain time intelligence functions).
When to Use Which
| Scenario | Use |
|---|---|
| Monthly sales report from Excel | Import |
| Live manufacturing floor dashboard | DirectQuery |
| 10 million row ERP table | DirectQuery or Import with aggregations |
| Weekly HR report from CSV | Import |
| Stock price ticker | DirectQuery |
📝 Quick Check
Test your understanding of this chapter
Q1. What is the benefit of query folding?
Q2. Which is NOT a data connectivity mode in Power BI?
Q3. Live Connection is typically used with:
Answer all 3 questions above to mark this chapter complete.
What is Power Query?
Power Query is the ETL (Extract, Transform, Load) engine inside Power BI. Every transformation you apply is recorded as a step using a language called M. You can see and edit these steps in the Applied Steps panel on the right side of the Query Editor.
Opening Power Query Editor
- Click Home > Transform Data to open the Power Query Editor window.
- Left panel: list of all queries (tables). Center: data preview. Right: Applied Steps.
- Each step is an M expression — click the fx bar to see or edit the formula.
- The Query Editor is non-destructive — changes apply only when you click Close & Apply.
Common First Steps on Any Dataset
- Promote Headers: Use first row as column names (Home > Use First Row as Headers).
- Change Type: Set correct data types for each column (Text, Number, Date, etc.).
- Remove Top Rows: Skip metadata rows that appear before the actual data.
- Filter Rows: Remove test data, blanks, or out-of-scope records.
- Rename Columns: Replace "Column1" with meaningful names like "Order_ID".
📝 Quick Check
Test your understanding of this chapter
Q1. What is Power Query also called in Power BI?
Q2. The language used in Power Query is:
Q3. Power Query is primarily used for:
Answer all 3 questions above to mark this chapter complete.
Common Column Transformations
- Split Column: Split "Chennai - Tamil Nadu" by delimiter " - " into two columns: City and State.
- Trim / Clean: Remove leading/trailing spaces (Trim) and non-printable characters (Clean).
- Replace Values: Replace "N/A" or "--" with null or a default value.
- Extract: Pull text before/after a delimiter, or extract by position (e.g., first 4 characters of an order code).
- Uppercase / Lowercase: Standardize text case for consistent joins.
- Date Transformations: Extract Year, Month, Quarter, Day of Week from a date column.
Example: Clean a Product Name Column
| Before | After (Trim + Proper Case) |
|---|---|
| laptop 15" | Laptop 15" |
| MOUSE wireless | Mouse Wireless |
| Keyboard USB | Keyboard Usb |
Number Transformations
- Round: Round to 2 decimal places (useful for currency amounts in Rs.).
- Absolute Value: Convert negative returns to positive for analysis.
- Percentage: Divide a column by another and set type to Percentage.
- Standard (Statistics): Create min, max, sum columns in one click via the Statistics option.
📝 Quick Check
Test your understanding of this chapter
Q1. How do you remove duplicate rows in Power Query?
Q2. Splitting a column by delimiter is found under:
Q3. To rename a column in Power Query, you:
Answer all 3 questions above to mark this chapter complete.
Merge Queries (JOIN)
Merge combines two tables horizontally based on a matching key — like a VLOOKUP or SQL JOIN.
- Left Outer: All rows from the left table + matching rows from right. (Most common)
- Inner: Only rows that match in both tables.
- Full Outer: All rows from both tables.
- Anti Join: Rows in left that have NO match in right — useful to find unmatched records.
Orders table: [OrderID, CustomerID, Amount]
Customers table: [CustomerID, CustomerName, City]
Merge on CustomerID (Left Outer)
Result: [OrderID, CustomerID, Amount, CustomerName, City]
Append Queries (UNION)
Append stacks tables vertically — like SQL UNION ALL. Use when you have the same structure across multiple files.
- Example: Monthly sales files Jan.csv, Feb.csv, Mar.csv — append all three into one Sales table.
- Append New: Creates a new query from two tables (non-destructive).
- Append to Existing: Adds rows to the first query.
- Column names must match (case-sensitive). Mismatched columns appear as null in the combined table.
Combining Folder of Files
- Get Data > Folder. Select folder containing 12 monthly CSV files.
- Power Query shows all files. Click "Combine & Transform" — auto-appends all files into one table.
- New monthly files dropped into the same folder are auto-picked up on next refresh.
📝 Quick Check
Test your understanding of this chapter
Q1. What does 'Merge Queries' do?
Q2. 'Append Queries' stacks tables:
Q3. Which join returns only matching rows from both tables?
Answer all 3 questions above to mark this chapter complete.
Custom Column (M Formula)
When built-in transformations aren't enough, write your own formula using M Language in Add Column > Custom Column.
// Calculate GST (18%) on Amount
= [Amount] * 0.18
// Combine First and Last Name
= [First_Name] & " " & [Last_Name]
// Classify sales amount
= if [Amount] > 100000 then "High"
else if [Amount] > 50000 then "Medium"
else "Low"
// Extract Year from Date
= Date.Year([Order_Date])
// Convert text "1,23,456" to number
= Number.From(Text.Remove([Amount_Text], {",", " "}))
Conditional Column (No-Code)
- Add Column > Conditional Column — build if/else logic with a form (no M typing).
- Great for classifying: Region = "South" if City in {Chennai, Bangalore, Hyderabad}.
Key M Language Concepts
- Case-sensitive:
Text.Upperworks;text.upperfails. - Null handling: Use
if [Col] = null then "Unknown" else [Col]to replace nulls. - List functions:
List.Sum({1,2,3})returns 6. Use inside custom columns. - Date functions:
Date.AddDays([Date], 30)adds 30 days to a date column.
= [Column] operation value and you can handle 80% of custom column needs.📝 Quick Check
Test your understanding of this chapter
Q1. To add a column multiplying two columns, you use:
Q2. Conditional Column in Power Query is like:
Q3. 'Unpivot Columns' converts:
Answer all 3 questions above to mark this chapter complete.
Data Profiling Tools in Power Query
- Column Quality: Shows % of Valid, Error, and Empty values per column as a colored bar.
- Column Distribution: Shows the distribution of values — how many unique values, which value appears most often.
- Column Profile: Detailed stats at the bottom — Min, Max, Average, Count, Null count, Error count.
- Enable these via View tab > Column Quality / Column Distribution / Column Profile.
Handling Data Quality Issues
- Nulls: Right-click column > Replace Values > replace null with 0 (numbers) or "Unknown" (text).
- Errors: Right-click column > Remove Errors (removes the row) or Replace Errors (fills with a value).
- Duplicates: Home > Remove Duplicates (removes entire duplicate rows). Or keep only unique by a key column.
- Outliers: Filter column to exclude values above/below a reasonable threshold.
Example: Profiling a Sales Amount Column
| Metric | Value | Action |
|---|---|---|
| Valid | 94% | Good |
| Errors | 3% | Replace Errors with 0 |
| Nulls | 3% | Replace Null with 0 |
| Min Value | -5,000 | Investigate negatives |
| Max Value | 98,50,000 | Verify large outlier |
📝 Quick Check
Test your understanding of this chapter
Q1. What does 'Close & Apply' do in Power Query?
Q2. Query folding improves performance by:
Q3. Where do you see the M code for a query?
Answer all 3 questions above to mark this chapter complete.
What is a Star Schema?
A star schema organizes data into one central Fact table surrounded by multiple Dimension tables. The fact table holds measurable events (sales, orders, transactions); dimensions describe who, what, where, and when.
Fact Table vs Dimension Table
| Type | Contains | Example |
|---|---|---|
| Fact Table | Numbers, IDs, dates | Sales: OrderID, ProductID, CustomerID, DateID, Amount |
| Dim_Product | Product details | ProductID, Name, Category, Brand |
| Dim_Customer | Customer details | CustomerID, Name, City, Segment |
| Dim_Date | Calendar attributes | DateID, Date, Year, Month, Quarter, Weekday |
Why Star Schema in Power BI?
- Power BI's VertiPaq engine is optimized for star schemas — better compression and faster queries.
- DAX time intelligence functions require a separate, contiguous Date dimension table.
- Slicers and filters work more predictably — filter once on a dimension and it flows to all related facts.
- Avoids many-to-many ambiguity issues that slow down reports and cause incorrect totals.
📝 Quick Check
Test your understanding of this chapter
Q1. A Star Schema consists of:
Q2. A fact table typically contains:
Q3. A dimension table typically contains:
Answer all 3 questions above to mark this chapter complete.
Creating Relationships
- Go to Model View. Power BI auto-detects relationships based on column names. Verify them manually.
- To create: drag a column from one table and drop onto the matching column in another table.
- To edit: double-click the relationship line to set cardinality and cross-filter direction.
Cardinality Types
- One-to-Many (1:*): Most common. One row in Dimension matches many rows in Fact. (e.g., one Product appears in many Orders)
- One-to-One (1:1): Rare. Both tables have unique values in the join column.
- Many-to-Many (*:*): Both tables have repeating values. Requires bridge table or special handling.
Filter Direction
- Single (Default): Filter flows from dimension to fact only. (Recommended for star schemas)
- Both (Bidirectional): Filter flows both ways. Can cause circular dependency issues — use carefully.
Active vs Inactive Relationships
You can have only one active relationship between two tables. If you need to analyze a fact table by two date fields (e.g., Order Date and Ship Date), create two relationships to the Date table. Only one can be active; use USERELATIONSHIP in DAX to activate the inactive one.
Ship Date Sales =
CALCULATE(
SUM(Sales[Amount]),
USERELATIONSHIP(Sales[ShipDate], Date[Date])
)
📝 Quick Check
Test your understanding of this chapter
Q1. Relationships in Power BI are created between tables using:
Q2. A one-to-many relationship means:
Q3. Cross-filter direction 'Both' should be used:
Answer all 3 questions above to mark this chapter complete.
Why You Need a Date Table
Time intelligence DAX functions (SAMEPERIODLASTYEAR, DATESYTD, PREVIOUSMONTH) require a dedicated, contiguous Date table marked as the official Date Table in your model. Without it, these functions either fail or give wrong results.
Creating a Date Table in DAX
Date =
ADDCOLUMNS(
CALENDARAUTO(),
"Year", YEAR([Date]),
"Month No", MONTH([Date]),
"Month Name", FORMAT([Date], "MMMM"),
"Quarter", "Q" & QUARTER([Date]),
"Weekday", FORMAT([Date], "dddd"),
"Week No", WEEKNUM([Date], 21),
"FY Quarter", "FY Q" & INT(MOD(MONTH([Date]) - 4, 12) / 3 + 1),
"Is Weekend", IF(WEEKDAY([Date],2) >= 6, TRUE(), FALSE())
)
CALENDARAUTO() automatically detects the min and max dates across all date columns in your model.
Mark as Date Table
- After creating, right-click the Date table in Fields pane > Mark as Date Table > select the Date column.
- Link the Date table to every fact table via the date key column.
- This enables all time intelligence DAX functions to work correctly.
📝 Quick Check
Test your understanding of this chapter
Q1. Why is a dedicated Date table recommended?
Q2. CALENDARAUTO() function:
Q3. A Date table must have:
Answer all 3 questions above to mark this chapter complete.
Calculated Columns
- Computed row by row, stored in the table (takes memory). Available in the Fields pane like any regular column.
- Can be used in slicers, rows of a matrix, or as an axis in a chart.
- Example:
GST Amount = Sales[Amount] * 0.18— added to every row in Sales table. - Evaluated during data refresh, not during visual interaction.
Measures
- Computed dynamically at query time based on the current filter context. NOT stored row by row.
- Must be used as a Value in a visual (not as axis or slicer).
- Example:
Total Sales = SUM(Sales[Amount])— changes dynamically when you filter by Region or Month. - Always prefer measures over calculated columns for aggregations.
Comparison
| Feature | Calculated Column | Measure |
|---|---|---|
| Row-level | Yes | No |
| Memory usage | High (stored) | Low (computed on demand) |
| Use in slicer | Yes | No |
| Context-aware | No | Yes |
| Best for | Categories, flags, derived text | All aggregations |
📝 Quick Check
Test your understanding of this chapter
Q1. What is a calculated column?
Q2. A DAX measure differs from a calculated column because:
Q3. Calculated columns are computed:
Answer all 3 questions above to mark this chapter complete.
When Does Many-to-Many Occur?
Many-to-many happens when the join column has duplicate values in BOTH tables. Example: a salesperson covers multiple regions, and a region has multiple salespersons. Neither table has a unique key for the join.
Solution 1: Bridge Table
Create a bridge (junction) table that resolves the many-to-many into two one-to-many relationships.
| SalesPerson table | Bridge table | Region table |
|---|---|---|
| SalesPersonID | SalesPersonID + RegionID | RegionID |
| Ravi: SP001 | SP001 + R01 | R01: Chennai |
| Priya: SP002 | SP001 + R02 | R02: Bangalore |
| SP002 + R01 |
Solution 2: Power BI Native M:M
- Power BI supports native many-to-many relationships since 2018. Set cardinality to Many to Many (*:*).
- Works well for budget vs actuals scenarios where both tables share a common dimension key.
- Limitation: bidirectional filtering is enabled by default — can cause performance issues in large models.
📝 Quick Check
Test your understanding of this chapter
Q1. Row-Level Security (RLS) restricts:
Q2. RLS roles are defined using:
Q3. To test an RLS role in Power BI Desktop, use:
Answer all 3 questions above to mark this chapter complete.
Reduce File Size
- Remove unused columns: Every column in the model takes memory. Delete anything not used in DAX or visuals.
- Use integer keys: Relationships on integers (1, 2, 3) are faster than on long text strings ("Chennai-Region-South-Zone").
- Avoid high cardinality text columns: A URL or long description column with millions of unique values bloats the model.
- Summarize imported data: Import pre-aggregated data (monthly totals) instead of millions of daily transaction rows when detail isn't needed.
DAX Performance Tips
- Use DIVIDE(numerator, denominator, 0) instead of numerator / denominator — handles division by zero gracefully.
- Use VAR in complex measures to calculate intermediate results once instead of repeatedly.
- Avoid nested CALCULATE statements more than 2 levels deep.
- Use Performance Analyzer (View tab) to measure how long each visual takes to render — identifies slow DAX measures.
Model View Best Practices
- Organize tables: Fact tables at center, Dimensions around them (like a star).
- Hide foreign key columns from the report view (right-click > Hide in Report View) — users should use dimension tables for filtering, not raw IDs.
- Create a dedicated Measures table (empty query + calculated measures only) to keep measures organized.
📝 Quick Check
Test your understanding of this chapter
Q1. What does cardinality mean in relationships?
Q2. Many-to-many relationships typically require:
Q3. The primary key in a relationship should have:
Answer all 3 questions above to mark this chapter complete.
What is DAX?
DAX (Data Analysis Expressions) is the formula language used in Power BI, Excel Power Pivot, and Analysis Services. It lets you create custom calculations — measures and calculated columns — that respond dynamically to filters and slicers in your reports.
DAX vs Excel Formulas
| Feature | Excel Formula | DAX Measure |
|---|---|---|
| Scope | Single cell | Entire column or filter context |
| Context-aware | No | Yes — changes with every slicer click |
| Time intelligence | Manual OFFSET tricks | Built-in functions (SAMEPERIODLASTYEAR etc.) |
| Performance | Slow on large data | Optimized for millions of rows |
DAX Syntax Basics
Measure Name = FUNCTION(Table[Column], [Optional Args])
// Example measures
Total Sales = SUM(Sales[Amount])
Order Count = COUNTROWS(Sales)
Avg Order = AVERAGE(Sales[Amount])
Max Sale = MAX(Sales[Amount])
- Table[Column] — always reference columns with table name prefix.
- Measures are created in the Fields pane > right-click table > New Measure.
- DAX is not case-sensitive:
SUM=sum. - Use // comments to document complex measures.
📝 Quick Check
Test your understanding of this chapter
Q1. What does DAX stand for?
Q2. SUM() in DAX adds:
Q3. CALCULATE() evaluates an expression in:
Answer all 3 questions above to mark this chapter complete.
Aggregation Functions
// Total Revenue (sum of all amounts)
Total Revenue = SUM(Sales[Amount])
// Number of orders
Order Count = COUNTROWS(Sales)
// Count non-blank values in a column
Product Count = COUNT(Products[ProductID])
// Count distinct customers
Unique Customers = DISTINCTCOUNT(Sales[CustomerID])
// Average order value
Avg Order Value = AVERAGE(Sales[Amount])
// Minimum and Maximum
Min Sale = MIN(Sales[Amount])
Max Sale = MAX(Sales[Amount])
SUMX — Row-by-Row Calculation
When you need to multiply two columns first and then sum the result, use SUMX:
// Revenue = Qty * Unit Price, summed across all rows
Revenue = SUMX(Sales, Sales[Qty] * Sales[UnitPrice])
// Gross Profit with discount
Gross Profit = SUMX(Sales, (Sales[UnitPrice] - Sales[CostPrice]) * Sales[Qty])
Example Output
| Region | Total Revenue (Rs.) | Order Count | Avg Order (Rs.) |
|---|---|---|---|
| Chennai | 18,50,000 | 124 | 14,919 |
| Bangalore | 24,30,000 | 167 | 14,551 |
| Hyderabad | 12,75,000 | 89 | 14,326 |
| Total | 55,55,000 | 380 | 14,618 |
📝 Quick Check
Test your understanding of this chapter
Q1. SUMX() vs SUM() — SUMX:
Q2. FILTER() returns:
Q3. RELATED() in calculated columns:
Answer all 3 questions above to mark this chapter complete.
What is CALCULATE?
CALCULATE is the most powerful DAX function. It evaluates an expression (like SUM) and applies additional or modified filter context on top of whatever filters are already active from slicers.
// Sales only for South region — ignores whatever slicer is selected
South Sales =
CALCULATE(SUM(Sales[Amount]), Sales[Region] = "South")
// Sales for current year
Current Year Sales =
CALCULATE(SUM(Sales[Amount]), YEAR(Sales[OrderDate]) = YEAR(TODAY()))
// Remove all date filters (show grand total regardless of time slicer)
All Time Sales =
CALCULATE(SUM(Sales[Amount]), ALL(Date))
// Sales % of total
Sales % =
DIVIDE(
SUM(Sales[Amount]),
CALCULATE(SUM(Sales[Amount]), ALL(Sales))
)
Filter Context vs Row Context
- Filter Context: The set of filters from slicers, row/column headers in a matrix, and CALCULATE modifiers. Measures live in filter context.
- Row Context: The current row being evaluated. Exists inside calculated columns and iterator functions (SUMX, FILTER, etc.).
- CALCULATE converts row context to filter context — this is the core of understanding advanced DAX.
FILTER Function
// Sales where Amount > 50,000
High Value Sales =
CALCULATE(
SUM(Sales[Amount]),
FILTER(Sales, Sales[Amount] > 50000)
)
// Sales for specific product category
Electronics Sales =
CALCULATE(
SUM(Sales[Amount]),
Products[Category] = "Electronics"
)
📝 Quick Check
Test your understanding of this chapter
Q1. DIVIDE(numerator, denominator, alternate) — when denominator is 0:
Q2. VAR in DAX stores:
Q3. RETURN in a VAR block:
Answer all 3 questions above to mark this chapter complete.
Prerequisites
- A Date table marked as Date Table in Model View (covered in Chapter 4.3).
- Date table connected to your fact table via the date column.
Common Time Intelligence Measures
// Year-to-Date Sales
Sales YTD = CALCULATE(SUM(Sales[Amount]), DATESYTD(Date[Date]))
// Same period last year
Sales LY =
CALCULATE(SUM(Sales[Amount]), SAMEPERIODLASTYEAR(Date[Date]))
// Year-over-year growth %
YoY Growth % =
VAR CurrentSales = SUM(Sales[Amount])
VAR LastYearSales = CALCULATE(SUM(Sales[Amount]), SAMEPERIODLASTYEAR(Date[Date]))
RETURN
DIVIDE(CurrentSales - LastYearSales, LastYearSales, 0)
// Month-to-Date
Sales MTD = CALCULATE(SUM(Sales[Amount]), DATESMTD(Date[Date]))
// Previous month
Sales Prev Month =
CALCULATE(SUM(Sales[Amount]), PREVIOUSMONTH(Date[Date]))
Example: YoY Comparison Table
| Month | Current Year (Rs.) | Last Year (Rs.) | YoY Growth |
|---|---|---|---|
| January | 8,50,000 | 7,20,000 | +18.1% |
| February | 9,20,000 | 8,10,000 | +13.6% |
| March | 10,50,000 | 9,40,000 | +11.7% |
📝 Quick Check
Test your understanding of this chapter
Q1. SAMEPERIODLASTYEAR() returns:
Q2. TOTALYTD() calculates:
Q3. Time intelligence functions require:
Answer all 3 questions above to mark this chapter complete.
RANKX — Dynamic Ranking
// Rank products by sales (1 = highest)
Product Rank =
RANKX(
ALL(Products[ProductName]),
[Total Revenue],
,
DESC,
Dense
)
// Only show top 5 products
Top 5 Flag = IF([Product Rank] <= 5, "Top 5", "Others")
TOPN — Retrieve Top N Rows
// Sum of top 3 customers' sales
Top 3 Customer Sales =
CALCULATE(
SUM(Sales[Amount]),
TOPN(3, ALL(Customers[CustomerName]), [Total Revenue], DESC)
)
VAR / RETURN — Variables
Variables store intermediate results, making complex measures readable and faster (computed once).
Profit Margin % =
VAR TotalRevenue = SUM(Sales[Amount])
VAR TotalCost = SUM(Sales[CostAmount])
VAR GrossProfit = TotalRevenue - TotalCost
RETURN
DIVIDE(GrossProfit, TotalRevenue, 0)
// SWITCH(TRUE()) pattern — replaces nested IF
Sales Category =
SWITCH(
TRUE(),
[Total Revenue] >= 1000000, "Platinum",
[Total Revenue] >= 500000, "Gold",
[Total Revenue] >= 100000, "Silver",
"Bronze"
)
📝 Quick Check
Test your understanding of this chapter
Q1. RANKX() is used to:
Q2. SWITCH(TRUE(), ...) in DAX is equivalent to:
Q3. USERPRINCIPALNAME() is used for:
Answer all 3 questions above to mark this chapter complete.
The Visual Selection Framework
| What You Want to Show | Best Visual |
|---|---|
| Compare values across categories | Bar Chart / Column Chart |
| Trend over time | Line Chart / Area Chart |
| Part of a whole | Donut Chart / Treemap / 100% Stacked Bar |
| Relationship between two measures | Scatter Chart |
| Geographic distribution | Map / Filled Map / Shape Map |
| Single KPI with target | Card / KPI Visual / Gauge |
| Detailed data table | Table / Matrix |
| Ranking / Distribution | Bar Chart sorted DESC |
Common Mistakes to Avoid
- Pie charts with 8+ slices: Hard to read. Use bar chart instead.
- 3D charts: Distort proportions. Always use 2D.
- Dual-axis line charts with different scales: Misleading. Use separate visuals with shared filters.
- Cluttered visuals: Remove gridlines, borders, data labels on every point — show only what adds value.
- Inappropriate use of Gauge: Gauges look great but waste space. Use KPI cards instead for most scenarios.
📝 Quick Check
Test your understanding of this chapter
Q1. Which chart type is best for trends over time?
Q2. A Card visual displays:
Q3. Stacked bar vs Clustered bar — stacked shows:
Answer all 3 questions above to mark this chapter complete.
Bar & Column Charts
- Clustered Bar: Compare multiple series side by side horizontally. Best for long category names.
- Clustered Column: Same but vertical. Best for time-series (months/quarters on X-axis).
- Stacked Column: Shows total + composition. Useful for revenue by product category over months.
- 100% Stacked: Compares proportions when absolute values differ greatly between categories.
Line Charts
- Best for continuous time-series data: daily sales, weekly production, monthly headcount.
- Add a forecast line (Analytics pane > Forecast) to project future trends.
- Use area chart when you want to emphasize the volume under the trend.
Combo Chart (Line + Column)
A combo chart overlays a line on a column chart — great for showing Revenue (columns) vs Profit Margin % (line) on the same time axis.
- Drag the first measure to Column Values; drag the second measure to Line Values.
- Format each series independently — different colors, data labels on/off.
- Add a secondary Y-axis when the two measures have very different scales (e.g., revenue in crores vs margin in %).
📝 Quick Check
Test your understanding of this chapter
Q1. What is a slicer used for?
Q2. Cross-filtering between visuals means:
Q3. Sync slicers feature allows:
Answer all 3 questions above to mark this chapter complete.
Table Visual
- Shows raw data rows. Add columns from Fields pane. Sort by clicking column headers.
- Add conditional formatting: background color scale on a number column highlights high/low values.
- Use Data bars (Format > Conditional Formatting > Data Bars) to add in-cell mini bar charts.
- Tables auto-paginate — users can scroll through thousands of rows.
Matrix Visual (Pivot Table)
- Rows + Columns + Values = dynamic cross-tabulation. Like a pivot table in Excel.
- Supports drill-down: if rows = Year > Quarter > Month, click the drill-down arrow to expand.
- Enable Subtotals and Grand Totals in Format pane.
- Apply conditional formatting on the Values to create a heat map matrix.
Card & Multi-Row Card
- Card: Shows a single large number with a label. Perfect for KPIs on a dashboard (Total Revenue, Headcount, OTD %).
- Multi-Row Card: Shows multiple key metrics in a stacked list — alternative to a table for summary stats.
- Format card: turn off category label, change font size to 36-48pt for impact, add border color matching your theme.
📝 Quick Check
Test your understanding of this chapter
Q1. What does the Format pane control?
Q2. Conditional formatting in tables can highlight based on:
Q3. Data labels on a chart show:
Answer all 3 questions above to mark this chapter complete.
Map Visual (Bubble Map)
- Add a location field (City, State, Country) to the Location bucket. Add a measure to Size — bubbles scale by value.
- Power BI uses Bing Maps to geocode location names. Precise lat/lon columns are more reliable for Indian tier-2 cities.
- Add a measure to Color Saturation to create a heatmap effect on the bubbles.
Filled Map (Choropleth)
- Fills geographic regions (states, countries) with color based on a measure.
- Add State to Location bucket. Add measure to Color Saturation — darker = higher value.
- For Indian state maps, ensure state names match Bing Maps spelling exactly (e.g., "Tamil Nadu" not "Tamilnadu").
ArcGIS Maps / Azure Maps
- Advanced geo visuals with layers, heat maps, and clustering. Available under Visualizations > More Visuals.
- Requires an ArcGIS/Azure account for full features. Basic version is free.
Example: Sales by Indian State
| State | Sales (Rs. Lakhs) |
|---|---|
| Tamil Nadu | 185 |
| Karnataka | 243 |
| Maharashtra | 312 |
| Telangana | 127 |
📝 Quick Check
Test your understanding of this chapter
Q1. Decomposition Tree visual is used for:
Q2. Key Influencers visual identifies:
Q3. Waterfall chart is best for showing:
Answer all 3 questions above to mark this chapter complete.
Custom Visuals from AppSource
- Click the three dots (...) in the Visualizations pane > Get more visuals > AppSource.
- Popular custom visuals: Bullet Chart, Chiclet Slicer, Calendar Visual, Sankey Chart, Word Cloud, Gantt Chart.
- Certified visuals (marked with a blue badge) are reviewed by Microsoft for security and quality.
- Import a .pbiviz file for offline environments: three dots > Import visual from file.
Power BI Themes
- A theme is a JSON file that sets colors, fonts, and default formatting for every visual in your report.
- Go to View > Themes — choose a built-in theme or import a custom JSON file.
- Create your company's branded theme (matching logo colors) and share the JSON file with your team.
Minimal Theme JSON Example
{
"name": "Lernus Academy Theme",
"dataColors": ["#f7c948","#1e6fbf","#2e8b57","#c0392b","#8e44ad"],
"background": "#ffffff",
"foreground": "#0f1e35",
"tableAccent": "#f7c948",
"visualStyles": {
"*": {
"*": {
"fontFamily": [{ "value": "Inter" }]
}
}
}
}
📝 Quick Check
Test your understanding of this chapter
Q1. Map visuals in Power BI need:
Q2. ArcGIS Maps vs standard Map — ArcGIS adds:
Q3. Filled Map visual fills:
Answer all 3 questions above to mark this chapter complete.
Slicers
- A slicer is an interactive filter widget on the report canvas. Users click it to filter all visuals on the page.
- Add a slicer: click Slicer visual from Visualizations pane, then drag a field into it (Year, Region, Category).
- Slicer types: List, Dropdown, Between (for numeric ranges), Relative Date (Last 7 days, This month).
- Change type in Format pane > Slicer Settings > Style.
- Use Sync Slicers (View > Sync Slicers) to make one slicer filter multiple pages simultaneously.
Report-Level, Page-Level, Visual-Level Filters
- Visual-level: Applies only to one visual. Drag a field to the Visual Filters bucket in the Filters pane.
- Page-level: Applies to all visuals on the current page.
- Report-level: Applies across all pages — use for permanent business filters (e.g., exclude test data, show only current year).
- Filters pane can be hidden from report viewers: Format > Filter pane > Hidden.
Slicer Best Practices
- Always add a "Select All" option for multi-select slicers.
- Group related slicers in a dedicated filter panel area (left or top of the page).
- Use dropdown slicers to save canvas space when you have many filter options.
- Add a Clear All Slicers button using a Blank Button + Reset All Slicers bookmark.
📝 Quick Check
Test your understanding of this chapter
Q1. A Power BI report page can contain:
Q2. Page navigation buttons are used to:
Q3. Bookmarks in Power BI save:
Answer all 3 questions above to mark this chapter complete.
Drill-Through
Drill-through lets users right-click a data point and navigate to a detail page filtered to that specific item.
- Create a detail page (e.g., "Customer Detail"). In the Filters pane, drag the drill-through field (CustomerName) to the Drill-Through section.
- Power BI auto-adds a Back button on the detail page.
- Right-click any customer name in your main report > Drill through > Customer Detail.
- The detail page shows all visuals filtered to that one customer.
Bookmarks
- A bookmark saves the current state: visible pages, slicer values, visual visibility, scroll position.
- View > Bookmarks Pane > Add. Name your bookmark (e.g., "Default View", "South Region View").
- Link a button to a bookmark: Insert > Button > set Action = Bookmark > select bookmark.
- Use case: Toggle between two charts on the same space — one bookmark shows Chart A hidden, one shows Chart B hidden. Button toggles between them.
Report Tooltips
- Create a dedicated Tooltip page (Page Information > Allow use as tooltip = ON, set Page Size = Tooltip).
- Build rich visuals on the tooltip page. In your main visual's Format > Tooltip > Type = Report Page > select your tooltip page.
- Hovering over any data point shows the custom tooltip page — much richer than the default tooltip.
📝 Quick Check
Test your understanding of this chapter
Q1. To publish a report from Power BI Desktop, go to:
Q2. After publishing, your report appears in:
Q3. A Power BI workspace is:
Answer all 3 questions above to mark this chapter complete.
Publishing Steps
- Save your .pbix file in Desktop. Click Home > Publish.
- Sign in with your Microsoft 365 account. Select a Workspace (My Workspace for personal use; shared workspace for team).
- Publishing uploads both the Report and the Dataset (data model) to Power BI Service.
- Open app.powerbi.com in your browser to see the published report.
Sharing Reports
- Share button: Enter colleague email. They receive a link. Requires both parties to have Power BI Pro or the workspace to be in Premium capacity.
- Publish to web (public): Creates a public iframe embed link — anyone with the link can view. Do NOT use for sensitive business data.
- Embed in Teams: Add Power BI tab to a Teams channel — team members see live report inside Teams.
- App: Package multiple reports into a Power BI App and distribute to a large group at once.
Workspaces
- My Workspace: Personal space. Reports visible only to you.
- Shared Workspace: Team space. Add members with roles: Admin, Member, Contributor, Viewer.
- Only Admins and Members can publish reports to a shared workspace.
📝 Quick Check
Test your understanding of this chapter
Q1. Pinning a visual to a dashboard:
Q2. Power BI dashboards support:
Q3. Q&A feature on a dashboard allows:
Answer all 3 questions above to mark this chapter complete.
What is RLS?
Row-Level Security restricts which data rows a user can see in a published report. A Chennai regional manager sees only Chennai data; a Bangalore manager sees only Bangalore — same report, different data views based on login identity.
Setting Up RLS in Power BI Desktop
- Go to Modeling tab > Manage Roles.
- Create a new role (e.g., "South Region"). Add a DAX filter on the relevant table:
// Static RLS — only South region data
[Region] = "South"
// Dynamic RLS — filter by logged-in user's email
[SalesPersonEmail] = USERPRINCIPALNAME()
// Dynamic RLS with mapping table
[Region] IN
VALUES(
FILTER(RegionAccess, RegionAccess[UserEmail] = USERPRINCIPALNAME())[Region]
)
Assigning Users to Roles in Power BI Service
- Publish the report to the Service. Go to the Dataset > Security (three dots menu).
- Under each role, add the email addresses of the users who should be in that role.
- Test RLS as a specific user: Dataset > Security > Test as role.
📝 Quick Check
Test your understanding of this chapter
Q1. Scheduled refresh in Power BI Service requires what for on-premises data?
Q2. Power BI Pro allows up to how many scheduled refreshes per day?
Q3. Data alerts notify you when:
Answer all 3 questions above to mark this chapter complete.
Scheduled Data Refresh
- After publishing, open the Dataset in Power BI Service > Settings > Scheduled Refresh.
- Toggle "Scheduled Refresh" ON. Set frequency: Daily at 7 AM, or multiple times per day (up to 8x for Pro, 48x for Premium).
- Power BI Service re-runs your data queries at the scheduled time and updates the report automatically.
- Set up email notifications for refresh failure.
On-Premises Data Gateway
- If your data source is on a local server (SQL Server on your office machine, local Excel file), you need a Data Gateway.
- Download Power BI Gateway from powerbi.microsoft.com/gateway. Install on a machine that has access to the data source and stays ON 24/7.
- Configure the gateway in Power BI Service: Settings (gear icon) > Manage Gateways > add data source connection credentials.
- The gateway acts as a secure tunnel between Power BI cloud and your on-premises data.
Gateway Types
| Type | Use Case |
|---|---|
| Standard (Enterprise) Gateway | Multiple users, multiple data sources, 24/7 refresh |
| Personal Mode Gateway | Single user, personal datasets only |
| No Gateway needed | Cloud sources: Azure SQL, SharePoint Online, Dataverse |
📝 Quick Check
Test your understanding of this chapter
Q1. RLS in Power BI Service restricts:
Q2. To share a Power BI report, the recipient needs at minimum:
Q3. An App in Power BI Service is:
Answer all 3 questions above to mark this chapter complete.
Project Overview
Build a complete sales analytics dashboard for a fictional company "Vega Electronics" — a Chennai-based electronics distributor with 4 regions, 3 product categories, and 2 years of monthly sales data.
Data Model
- Sales (Fact): OrderID, Date, ProductID, CustomerID, Region, Qty, Amount, Cost
- Products (Dim): ProductID, ProductName, Category, Brand
- Customers (Dim): CustomerID, CustomerName, City, Segment
- Date (Dim): Date, Year, Month, Quarter, Weekday
Key DAX Measures to Create
Total Revenue = SUM(Sales[Amount])
Total Cost = SUM(Sales[Cost])
Gross Profit = [Total Revenue] - [Total Cost]
GP Margin % = DIVIDE([Gross Profit], [Total Revenue], 0)
Revenue LY = CALCULATE([Total Revenue], SAMEPERIODLASTYEAR(Date[Date]))
Revenue YTD = CALCULATE([Total Revenue], DATESYTD(Date[Date]))
YoY % = DIVIDE([Total Revenue] - [Revenue LY], [Revenue LY], 0)
Product Rank = RANKX(ALL(Products[ProductName]), [Total Revenue], , DESC, Dense)
Dashboard Pages
- Page 1 — Executive Summary: 4 KPI cards (Revenue, GP Margin, Orders, Customers) + Revenue trend line + Region map.
- Page 2 — Product Performance: Top 10 products bar chart + Category donut + GP Margin by brand matrix.
- Page 3 — Customer Analysis: Revenue by customer segment + RFM scatter + Top 10 customers table.
- Page 4 — Detail (Drill-Through): Order-level table filtered by customer or product.
📝 Quick Check
Test your understanding of this chapter
Q1. In a Sales Dashboard, the typical fact table is:
Q2. YTD Sales measure uses which DAX function?
Q3. Sales vs Target is best shown as:
Answer all 3 questions above to mark this chapter complete.
Project Overview
Build an HR metrics dashboard for a manufacturing company with 500 employees across 5 departments in Chennai. Track headcount, attrition, leave utilization, and payroll summary.
Key HR Measures
// Total active employees
Headcount = CALCULATE(COUNTROWS(Employees), Employees[Status] = "Active")
// Attrition rate
Attrition Rate % =
DIVIDE(
CALCULATE(COUNTROWS(Employees), Employees[Status] = "Resigned"),
[Headcount] + CALCULATE(COUNTROWS(Employees), Employees[Status] = "Resigned"),
0
)
// Average tenure in years
Avg Tenure Years =
AVERAGEX(
FILTER(Employees, Employees[Status] = "Active"),
DATEDIFF(Employees[JoiningDate], TODAY(), YEAR)
)
// Total payroll
Total Payroll = SUMX(Employees, Employees[BasicSalary] + Employees[Allowances])
// Leave utilization %
Leave Utilized % = DIVIDE(SUM(Leave[LeaveDays]), SUM(Leave[LeaveEntitlement]), 0)
Dashboard Pages
- Page 1 — Overview: Headcount card, Attrition % card, Avg Tenure, New Joiners this month, Department breakdown donut.
- Page 2 — Attrition Analysis: Monthly attrition trend, Department-wise attrition bar chart, Attrition by tenure bucket.
- Page 3 — Payroll Summary: Total payroll by department, Salary grade distribution, Payroll cost trend YTD.
📝 Quick Check
Test your understanding of this chapter
Q1. HR Analytics typically tracks:
Q2. Attrition rate is calculated as:
Q3. A Matrix visual is useful for HR because:
Answer all 3 questions above to mark this chapter complete.
Project Overview
Build a financial P&L (Profit & Loss) dashboard and Budget vs Actuals comparison for a mid-size company. Data comes from a SQL Server GL (General Ledger) table with account codes, amounts, and periods.
Key Financial Measures
// Actuals from GL
Actual Revenue =
CALCULATE(SUM(GL[Amount]), GL[AccountType] = "Revenue")
Actual Expenses =
CALCULATE(SUM(GL[Amount]), GL[AccountType] = "Expense")
Net Profit = [Actual Revenue] - [Actual Expenses]
Net Margin % = DIVIDE([Net Profit], [Actual Revenue], 0)
// Budget vs Actuals
Budget Revenue = SUM(Budget[Amount])
Revenue Variance = [Actual Revenue] - [Budget Revenue]
Revenue Variance % = DIVIDE([Revenue Variance], [Budget Revenue], 0)
// Budget utilization
Budget Utilized % = DIVIDE([Actual Expenses], SUM(Budget[BudgetAmount]), 0)
P&L Table (Matrix Visual)
| Line Item | Budget (Rs.) | Actual (Rs.) | Variance |
|---|---|---|---|
| Total Revenue | 1,20,00,000 | 1,28,50,000 | +7.1% |
| COGS | 72,00,000 | 76,20,000 | -5.8% |
| Gross Profit | 48,00,000 | 52,30,000 | +9.0% |
| Operating Expenses | 24,00,000 | 22,80,000 | +5.0% |
| Net Profit | 24,00,000 | 29,50,000 | +22.9% |
📝 Quick Check
Test your understanding of this chapter
Q1. Financial P&L reports in Power BI often use:
Q2. Actual vs Budget variance is best shown as:
Q3. To show running totals in a financial report:
Answer all 3 questions above to mark this chapter complete.
Project Overview
Build a supply chain operations dashboard tracking On-Time Delivery (OTD), inventory levels, supplier performance, and procurement spend for a manufacturing company with 3 plants and 50+ suppliers.
Key Supply Chain Measures
// On-Time Delivery %
OTD % =
DIVIDE(
CALCULATE(COUNTROWS(Deliveries), Deliveries[ActualDate] <= Deliveries[PromisedDate]),
COUNTROWS(Deliveries),
0
)
// Average lead time in days
Avg Lead Time =
AVERAGEX(
PurchaseOrders,
DATEDIFF(PurchaseOrders[PODate], PurchaseOrders[GRNDate], DAY)
)
// Inventory turnover ratio
Inventory Turnover =
DIVIDE([Total COGS], AVERAGE(Inventory[InventoryValue]))
// Days of inventory on hand
Days Inventory = DIVIDE(365, [Inventory Turnover])
// Supplier spend by category
Supplier Spend = SUM(PurchaseOrders[POAmount])
Dashboard Pages
- Page 1 — Overview: OTD % gauge, Avg Lead Time card, Total Procurement Spend YTD, Spend by category donut.
- Page 2 — Supplier Performance: OTD % by supplier bar chart, Lead time vs. spend scatter chart, Top 10 suppliers by spend table.
- Page 3 — Inventory: Days on hand by material group, Inventory value trend, Slow-moving stock flags (items with no movement in 90 days).
📝 Quick Check
Test your understanding of this chapter
Q1. Supply chain dashboards typically monitor:
Q2. Days Inventory Outstanding (DIO) measures:
Q3. For supply chain geo-analysis, the most appropriate visual is:
Answer all 3 questions above to mark this chapter complete.
Instructions
Answer all 20 questions. You need 80% (16 correct) to pass and receive your certificate. Take your time — there is no time limit.
📝 Quick Check
Test your understanding of this chapter
Q1. The Power BI certification exam is known as:
Q2. The PL-300 exam tests knowledge of:
Q3. A recommended practice before the PL-300 exam is:
Answer all 3 questions above to mark this chapter complete.