Objective. Students import data from a CSV file, an Excel workbook, and a SQL Server or PostgreSQL database into Power BI Desktop and apply Power Query transformations to produce a clean, typed table.
This lesson, its worked examples and its practice questions has not yet been verified by an industry-certified professional or by a certification or approval body. It is a study draft and may contain errors. Do not use it as instructions for work on a job site or on live equipment. Always follow your instructor, your supervising professional, and current official references and regulations.
VoTechWorks program approval and accreditation are still in progress. Credentials are issued only by the certifying bodies named in each program, after their own exams.
Before any chart or dashboard is built, the underlying data must be accurate, consistently typed, and free of structural problems. Power BI Desktop provides two tightly connected tools for this work: the Get Data dialog, which establishes connections to sources, and the Power Query Editor, which transforms raw data into analysis-ready tables. Errors introduced here—a column typed as text instead of a number, a stray duplicate row, a mismatched date format—will silently corrupt every visual downstream. Taking time to clean and verify data in Power Query is therefore a foundational professional habit, not an optional step.
Power BI Desktop can connect to hundreds of source types. For this lab you will use three:
Every connection produces a query in Power Query Editor. Think of each query as a recipe: it records every transformation step and replays them in order whenever the data is refreshed.
When you click Transform Data, Power Query Editor opens. Key areas:
Promote headers. When a CSV loads with generic column names (Column1, Column2 …), use Home → Use First Row as Headers. This adds a PromotedHeaders step that shifts row 1 into the column-name row.
Change data types. Every column must carry the correct type: Whole Number, Decimal Number, Date, Text, etc. Power Query auto-detects types on import, but auto-detection is not always correct—especially for columns that contain leading zeros (zip codes, permit IDs) that should remain Text. Click the type icon in the column header and select the correct type. Changing a type adds a Changed Type step.
Remove duplicates. Select one or more key columns, right-click, and choose Remove Duplicates. This is row-level deduplication based on the selected columns. Always confirm the row count before and after; the status bar at the bottom of the editor shows the current row count.
Merge queries. Merging is Power Query's equivalent of a SQL JOIN. Use Home → Merge Queries, select the two queries, pick the matching column(s), and choose the join kind (Left Outer is the most common for building fact tables). After merging, expand the nested table column to surface the columns you need.
A null in Power Query represents an absent value. Type mismatches occur when a column typed as, say, Whole Number contains a null or a text string such as "N/A". Power Query will flag these with an error indicator on the column header. Fix strategies include:
Every Applied Step is expressed in M, Power Query's functional formula language. You do not need to memorize M syntax, but you do need to be able to read and make small edits. The Advanced Editor (Home → Advanced Editor) shows the full M script for a query as a single function. A typical row-filter step looks like:
```
= Table.SelectRows(#"Changed Type", each [Budget] > 50000)
```
This keeps only rows where the Budget column exceeds 50,000. When you modify a step in the Advanced Editor, Power Query validates syntax on close; a red underline means a syntax error. Always verify the resulting row count in the status bar against an expected value before closing the editor.
A broken file path is one of the most common errors in shared .pbix files. If a CSV was connected from a personal desktop path (C:\Users\YourName\…) and the file is moved or the .pbix is opened on another machine, Power Query will show a DataSource.Error. Fix it by selecting the Source step in Applied Steps and editing the path in the formula bar or via Home → Data Source Settings.
Data safety in analytics means protecting data integrity and, where applicable, personally identifiable information (PII). During lab:
Before submitting, check:
1. Zero error indicators on column headers and in the Queries pane.
2. All columns carry the correct data type icon.
3. The merged fact table row count matches the instructor's answer key exactly.
4. Applied Steps are named clearly and contain no unused or duplicate steps.
Answer each question, then check it. Nothing is recorded; this is your own practice.
A free tech program — complimentary, as our commitment to get America working. Help us build VoTechWorks. Tell us what works, what doesn’t, and what you want to learn.
Does the school offer financial aid?
No. We don’t offer financial aid because we’re free. No, really: completely free.
Do you offer industry certification?
No. We are not certified yet, so we can’t offer that to students. What we do offer is knowledge and understanding of a trade.
Enroll first in the trade you’re interested in. You get your key, your program opens, and you begin studying.
Enroll free →