Hiring Partners
Segilola Resources Operating LimitedTaviatech TechnologiesFCMBMTN NigeriaAdvans La Fayette Microfinance BankAboki AfricaFirst Bank of NigeriaOPay
← Power Query for Data Analysis Β· Lesson 3 of 17

Module Two

πŸ“– Every lesson in this course is free to read right here, no account needed. Create a free account to track your progress, take the exam, and earn your certificate.
3
Module 2 Β· Power Query – Cleaning Like a Pro

🧹 Module 2: Power Query – Cleaning Like a Pro

Hello again, data explorer! πŸ‘‹ In Module 1, we learned what Power Query is and how to do basic cleaning. Now, we will go deeper. We will learn how to fix common problems like extra spaces, wrong dates, and mixed text. We will also learn how to split columns and combine data from different sources. By the end of this module, you will be able to clean data like a professional! Let's dive in! πŸŠβ€β™‚οΈ


🎯 Learning Objectives

  • βœ… Trim extra spaces from text.
  • βœ… Fix date formats.
  • βœ… Split columns into multiple columns.
  • βœ… Combine columns into one.
  • βœ… Replace values (e.g., change "N/A" to "0").
  • βœ… Use conditional columns to create new data.
  • βœ… Group data to see totals.
  • βœ… Pivot and unpivot tables.
  • βœ… Merge queries from different sources.

πŸ“– Warm-up Story: The Bakery Mix-up

In a small bakery in Ibadan, Nigeria, the baker, Mr. Ade, had a problem. He kept records of his daily bread sales, but his data was messy. Some dates were written as "12/05/2025" and others as "May 12, 2025". Some customer names had extra spaces like " Chidi ". He also had a column called "Full Name" but he needed separate "First Name" and "Last Name". He spent hours fixing these problems by hand. Then his daughter, Ngozi, who had just learned Power Query, said, "Daddy, let me help!" She used Power Query to trim spaces, fix dates, split names, and even combine data from two different files. In just a few minutes, everything was perfect. Mr. Ade was amazed and gave Ngozi an extra piece of cake! πŸŽ‚

This module will teach you all the tricks Ngozi used!


πŸ“š Main Lessons

Lesson 1: Trim – Removing Extra Spaces

Definition: Trim means removing unwanted spaces from the beginning or end of text.

Why important: Extra spaces can make it hard to search or match data. "Chidi" and "Chidi " are not the same to a computer.

Simple explanation: It's like cleaning the edges of a paper before putting it in a frame.

Real-life example: A customer list has " Ada " – trim makes it "Ada".

School example: A teacher trims student names before printing certificates.

Home example: Your mom trims the grocery list to remove extra spaces.

Nigerian example: A bank trims account holder names to avoid mismatches.

Illustration:

   Before: "  Bola  "  β†’  After: "Bola"

Mini summary: Trim removes extra spaces from text.


Lesson 2: Clean – Removing Non-Printable Characters

Definition: Clean removes characters that are not visible, like line breaks or special symbols.

Why important: These characters can cause errors in calculations or sorting.

Simple explanation: Like wiping dust off a table before placing a book.

Real-life example: Data copied from a website may have hidden symbols – Clean removes them.

School example: A project list from a website has weird characters – Clean fixes it.

Home example: A contact list copied from an email has extra symbols.

Nigerian example: A farmer's crop data from a PDF has hidden line breaks.

Illustration:

   Before: "Mango🍎" (with hidden symbol)  β†’  After: "Mango"

Mini summary: Clean removes invisible characters.


Lesson 3: Fixing Date Formats

Definition: Dates can be written in many ways. Power Query can change them to a standard format.

Why important: If dates are in different formats, you cannot sort or calculate correctly.

Simple explanation: It's like making sure all your friends write their birthdays the same way: DD/MM/YYYY.

Real-life example: Change "2025-12-31" to "31-Dec-2025".

School example: Make all exam dates look the same in the school calendar.

Home example: Fix the dates on your family's holiday photos.

Nigerian example: A school in Enugu standardises admission dates.

Illustration:

   Before: 12/31/2025  β†’  After: 31/12/2025 (consistent)

Mini summary: Standardise date formats for consistency.


Lesson 4: Splitting Columns

Definition: Splitting means taking one column and dividing it into two or more columns.

Why important: Sometimes one column has too much information, like "Chidi Okonkwo" – we want "Chidi" and "Okonkwo".

Simple explanation: Like cutting a sandwich into two halves.

Real-life example: Split "Full Name" into "First Name" and "Last Name".

School example: Split "Subject-Grade" into "Subject" and "Grade".

Home example: Split "Address" into "City" and "Street".

Nigerian example: Split "Lagos-Nigeria" into "City" and "Country".

Illustration:

   Before: "Chidi Okonkwo"  β†’  After: "Chidi" | "Okonkwo"

Mini summary: Split columns to separate information.


Lesson 5: Combining Columns

Definition: Combining merges two or more columns into one.

Why important: Sometimes you need a full name or full address from separate parts.

Simple explanation: Like joining two puzzle pieces to make a bigger piece.

Real-life example: Merge "First Name" and "Last Name" into "Full Name".

School example: Merge "Class" and "Section" into "Class-Section".

Home example: Merge "Street" and "Number" into "Address".

Nigerian example: Merge "LGA" and "State" into "Location".

Illustration:

   Before: "Chidi" | "Okonkwo"  β†’  After: "Chidi Okonkwo"

Mini summary: Combine columns to create new information.


Lesson 6: Replace Values

Definition: Replace Values changes specific text or numbers to something else.

Why important: You might have abbreviations or errors that need to be corrected.

Simple explanation: Like using a white-out pen to fix a mistake.

Real-life example: Change "N/A" to "0".

School example: Change "Absent" to "A".

Home example: Change "Kg" to "Kilogram".

Nigerian example: Change "LAG" to "Lagos".

Illustration:

   Before: "N/A"  β†’  After: "0"

Mini summary: Replace values to fix errors or standardise.


Lesson 7: Conditional Columns

Definition: A conditional column creates a new column based on a condition (if-then logic).

Why important: You can categorise data automatically.

Simple explanation: Like saying, "If it rains, take an umbrella; else, take a hat."

Real-life example: If sales > 1000, mark "High"; else "Low".

School example: If score β‰₯ 70, mark "Pass"; else "Fail".

Home example: If price > 500, mark "Expensive"; else "Cheap".

Nigerian example: If crop yield > 500kg, mark "Good Harvest".

Illustration:

   Sales  |  Category
   1500   |  High
   700    |  Low

Mini summary: Conditional columns add categories based on rules.


Lesson 8: Group By

Definition: Group By combines rows with the same value in a column and calculates something like sum, average, or count.

Why important: It summarises large data so you can see totals.

Simple explanation: Like grouping your toys by colour and counting how many of each colour.

Real-life example: Group sales by product to see total sales per product.

School example: Group students by class and count how many in each class.

Home example: Group expenses by category (food, rent) and sum them.

Nigerian example: Group farm produce by crop and sum the weight.

Illustration:

   Product  |  Sales
   Mango    |  100
   Mango    |  150
   Orange   |  200
   Group By Product β†’ Mango:250, Orange:200

Mini summary: Group By summarises data by categories.


Lesson 9: Pivot Columns

Definition: Pivot turns a column's values into multiple columns.

Why important: It makes data wider and easier to compare.

Simple explanation: Like turning a list of months into separate columns for January, February, etc.

Real-life example: Pivot months to see each month as a column.

School example: Pivot subjects to see each subject as a column with grades.

Home example: Pivot types of chores to see time spent per type.

Nigerian example: Pivot regions to see sales per region.

Illustration:

   Before: Month | Sales
           Jan   | 100
           Feb   | 200
   After:  Jan | Feb
           100 | 200

Mini summary: Pivot makes data wider.


Lesson 10: Unpivot Columns

Definition: Unpivot is the opposite of pivot – it turns multiple columns into rows.

Why important: Sometimes you need data tall (long) instead of wide.

Simple explanation: Like taking a table with Jan, Feb, Mar and turning it into a list of Month-Sales.

Real-life example: Unpivot monthly sales columns into a single column of months.

School example: Unpivot subject columns into a list of subjects.

Home example: Unpivot expense columns into a list of expenses.

Nigerian example: Unpivot crop yields by month.

Illustration:

   Before: Jan | Feb | Mar
           100 | 200 | 150
   After: Month | Sales
          Jan   | 100
          Feb   | 200
          Mar   | 150

Mini summary: Unpivot makes data taller (more rows).


Lesson 11: Merging Queries (from different sources)

Definition: Merging joins two queries (tables) from different sources using a common column.

Why important: You often have data in separate files – merging brings them together.

Simple explanation: Like sticking two photos together to make a bigger picture.

Real-life example: Merge customer data from Excel with order data from a database.

School example: Merge student list from one file with test scores from another.

Home example: Merge your toy list with a price list from a website.

Nigerian example: Merge school attendance from Excel with exam results from CSV.

Illustration:

   Query1: StudentID, Name
   Query2: StudentID, Score
   Merge β†’ StudentID, Name, Score

Mini summary: Merging combines queries from different sources.


Lesson 12: Appending Queries

Definition: Appending stacks two queries (tables) on top of each other.

Why important: If you have monthly sales in separate files, you can combine them into one.

Simple explanation: Like stacking building blocks.

Real-life example: Append January sales query with February sales query.

School example: Append test scores from Class A and Class B.

Home example: Append your allowance records from two years.

Nigerian example: Append daily sales from all branches.

Illustration:

   Query Jan: Ada, 100
   Query Feb: Bola, 200
   Append β†’ Ada, 100; Bola, 200

Mini summary: Append stacks queries vertically.


Lesson 13: Adding Custom Columns

Definition: A custom column is a new column that you create using a formula.

Why important: You can calculate new data, like total price = quantity * price.

Simple explanation: Like using a calculator to add numbers and writing the answer in a new column.

Real-life example: Create "Total Sales" = Quantity * Unit Price.

School example: Create "Total Score" = Test1 + Test2.

Home example: Create "Total Cost" = Items * Price.

Nigerian example: Create "Total Harvest" = Bags * Weight.

Illustration:

   Quantity | Price | Total (custom)
   2        | 500   | 1000

Mini summary: Custom columns let you create new data with formulas.


Lesson 14: Using the M Language (Introduction)

Definition: M is the language behind Power Query. It writes the steps for you.

Why important: You can see the code and learn to write your own advanced steps.

Simple explanation: It's like the recipe behind your favourite dish. Power Query writes it for you.

Real-life example: When you click a button, Power Query writes M code in the background.

School example: Like the teacher writing notes on the board – M is the notes.

Home example: The instructions for a toy are like M code.

Nigerian example: A recipe for jollof rice is like M code – step-by-step.

Illustration:

   let
       Source = Excel.Workbook(...),
       Table1 = Source{[Item="Sheet1"]}[Data]
   in
       Table1

Mini summary: M is the code behind your cleaning steps.


Lesson 15: Refreshing Data

Definition: Refreshing updates your query to get the latest data.

Why important: If new data comes in, you can refresh to see it without redoing all steps.

Simple explanation: Like turning on the tap to get fresh water.

Real-life example: You refresh your sales query to include today's sales.

School example: Refresh attendance to see who is present today.

Home example: Refresh your chore list to see new tasks.

Nigerian example: Refresh crop data after a new harvest.

Illustration:

   Click Refresh β†’ New data appears

Mini summary: Refresh brings in new data.


πŸ“– Key Vocabulary (with simple definitions)

  • Trim: Remove extra spaces.
  • Clean: Remove invisible characters.
  • Split: Divide one column into many.
  • Combine: Merge columns into one.
  • Replace Values: Change specific text or numbers.
  • Conditional Column: New column based on an if-then rule.
  • Group By: Summarise data by categories.
  • Pivot: Turn rows into columns.
  • Unpivot: Turn columns into rows.
  • Merge: Join two queries side by side.
  • Append: Stack queries top to bottom.
  • Custom Column: Column created with a formula.
  • M Language: The code language of Power Query.
  • Refresh: Update data.

🧠 Important Concepts

  • Data transformation is the process of changing data to make it useful.
  • Consistency is key – all data should be in the same format.
  • Reusability – once you create a query, you can reuse it with new data by refreshing.
  • Automation – Power Query automates repetitive cleaning tasks.
  • Data types still matter – always check them after transformations.

πŸ“ Step-by-Step Explanations

Trim and Clean:

  1. Select the column.
  2. Go to Transform β†’ Format β†’ Trim (or Clean).

Split Column:

  1. Select the column.
  2. Go to Transform β†’ Split Column β†’ By Delimiter (e.g., space).
  3. Choose "At each occurrence" or "At the left-most delimiter".

Combine Columns:

  1. Select columns.
  2. Go to Add Column β†’ Merge Columns.
  3. Choose a separator (e.g., space).

Replace Values:

  1. Select column.
  2. Go to Transform β†’ Replace Values.
  3. Enter value to find and value to replace with.

Conditional Column:

  1. Go to Add Column β†’ Conditional Column.
  2. Set column name, condition (if), and output.

Group By:

  1. Go to Transform β†’ Group By.
  2. Choose column to group by.
  3. Choose aggregation (Sum, Average, Count).

Pivot:

  1. Select column to pivot.
  2. Go to Transform β†’ Pivot Column.
  3. Choose values column and aggregation.

Unpivot:

  1. Select columns to unpivot.
  2. Go to Transform β†’ Unpivot Columns.

Merge Queries:

  1. Go to Home β†’ Merge Queries.
  2. Select the second query and matching columns.
  3. Choose join kind (usually Left Outer).

Append Queries:

  1. Go to Home β†’ Append Queries.
  2. Select the second query.

Custom Column:

  1. Go to Add Column β†’ Custom Column.
  2. Write formula (e.g., [Quantity] * [Price]).

🌍 Real-life Examples

  • Retail: Clean product names by trimming spaces and replacing abbreviations.
  • Healthcare: Split patient names, clean addresses, and group by disease.
  • Finance: Replace "NULL" with 0, pivot months for cash flow.
  • Education: Group students by class, pivot subjects to see grade distribution.

πŸ‡³πŸ‡¬ Nigerian Examples

  • Bank: Trim account holder names, replace "N/A" with "0" in transaction data.
  • Agriculture: Group crop data by state, pivot to see monthly yields.
  • School: Split student names, combine class and stream, conditional column for pass/fail.
  • Market: Clean item names, replace misspellings, unpivot weekly sales.

🧸 Fun Examples Children Can Relate To

  • Toys: Trim toy names, split "LEGO Star Wars" into "LEGO" and "Star Wars".
  • Games: Group video game scores by player, pivot to see scores per level.
  • Books: Combine author first and last name, conditional column for "Fiction" or "Non-fiction".
  • Snacks: Replace "choc" with "chocolate", group by flavour.

🏠 Everyday Examples

  • Grocery: Trim item names, replace "ltr" with "litre".
  • Chores: Split "Clean Room" into "Clean" and "Room".
  • Allowance: Group by week, sum amounts.
  • Phone contacts: Combine first and last name, trim extra spaces.

πŸ‘©β€πŸ« Teacher Notes

  • Use the bakery story to motivate students.
  • Demonstrate each step live in Excel.
  • Provide a messy dataset for students to practice all transformations.
  • Encourage students to create their own conditional columns.
  • Emphasise that practice is key – the more they do, the better they get.

πŸ‘ͺ Parent Tips

  • Help your child find a messy dataset online (like weather data).
  • Let them practice trimming and splitting at home.
  • Show them how to refresh data when new information comes.
  • Praise their efforts and encourage experimentation.

πŸ’‘ Interesting Facts

  • Power Query can handle over 1 million rows of data.
  • It can connect to databases like SQL Server and Oracle.
  • Power Query is used by data analysts in almost every industry.
  • The "M" language is named after the "Mashup" concept.
  • You can use Power Query to combine data from Facebook and Twitter.

πŸ€” Did You Know?

  • Did you know that you can use Power Query to clean data from your email attachments?
  • Did you know that Power Query can automatically detect data types for you?
  • Did you know that you can share your Power Query steps with friends by sending them the Excel file?

πŸ”” Remember This

  • 🧼 Trim and Clean to remove unwanted characters.
  • βœ‚οΈ Split columns to separate information.
  • βž• Combine columns to create full names or addresses.
  • πŸ”„ Replace values to fix errors.
  • ❓ Conditional columns add categories.
  • πŸ“Š Group By summarises data.
  • πŸ”„ Pivot and Unpivot change the shape of your table.
  • πŸ”— Merge and Append combine data from different sources.

⚠️ Common Mistakes

  • Mistake 1: Not trimming spaces – leads to mismatches.
  • Mistake 2: Splitting by the wrong delimiter (e.g., using comma instead of space).
  • Mistake 3: Forgetting to change data types after splitting.
  • Mistake 4: Grouping by wrong column – getting wrong totals.
  • Mistake 5: Pivoting without selecting the correct value column.
  • Mistake 6: Merging on columns with different data types.

βœ… Best Practices

  • Always trim and clean text columns first.
  • Standardise date formats early.
  • Use conditional columns to add meaningful categories.
  • Group and pivot only when needed.
  • Name your queries clearly (e.g., "SalesData_Cleaned").
  • Refresh to test if your query works with new data.

πŸ“Š Illustrations

Flowchart: Cleaning Process

   [ Load Data ]
        |
        V
   [ Trim & Clean ]
        |
        V
   [ Split/Combine ]
        |
        V
   [ Replace Values ]
        |
        V
   [ Conditional Column ]
        |
        V
   [ Group / Pivot ]
        |
        V
   [ Merge / Append ]
        |
        V
   [ Load to Excel ]

Timeline: Advanced Steps

   1. Trim   β†’  2. Clean  β†’  3. Split  β†’  4. Combine
        ↓          ↓            ↓            ↓
   5. Replace  β†’  6. Conditional  β†’  7. Group By
        ↓              ↓                ↓
   8. Pivot   β†’  9. Unpivot  β†’  10. Merge/Append

Comparison: Pivot vs Unpivot

FeaturePivotUnpivot
EffectMakes data widerMakes data taller
ColumnsIncreasesDecreases
RowsDecreasesIncreases
Use caseComparative analysisNormalisation

πŸ“Œ End-of-Module Summary

Congratulations! πŸŽ‰ You have completed Module 2. You now know how to:

  • Trim and clean text.
  • Split and combine columns.
  • Replace values and create conditional columns.
  • Group, pivot, and unpivot data.
  • Merge and append queries.
  • Add custom columns and refresh data.

You are now a Power Query cleaning expert! Keep practising with different datasets.


❓ Frequently Asked Questions (10)

  1. What is the difference between Trim and Clean? Trim removes spaces, Clean removes invisible characters.
  2. Can I split a column by multiple delimiters? Yes, you can split by delimiter and choose options.
  3. What is the use of conditional columns? To create categories based on conditions.
  4. How do I undo a pivot? Use Unpivot to reverse it.
  5. Can I merge more than two queries? Yes, you can merge multiple queries step by step.
  6. What is the difference between Merge and Append? Merge adds columns, Append adds rows.
  7. Can I use custom formulas in custom columns? Yes, you can write formulas like [Qty]*[Price].
  8. What does Refresh do? Updates the data with the latest from the source.
  9. Is the M language difficult to learn? No, Power Query writes it for you – you can learn gradually.
  10. Can I reuse a query with new data? Yes, just refresh or change the source.

πŸ“ Review Questions (15)

  1. What does Trim do?
  2. What does Clean do?
  3. Why would you split a column?
  4. How do you combine two columns?
  5. What is Replace Values used for?
  6. What is a conditional column?
  7. What does Group By do?
  8. What is the difference between Pivot and Unpivot?
  9. How do you merge two queries?
  10. How do you append queries?
  11. What is a custom column?
  12. What is the M language?
  13. What does Refresh do?
  14. Give an example of a conditional column rule.
  15. Why is cleaning data important?

✏️ Fill-in-the-Blank

  1. Trim removes _______________ spaces. (extra)
  2. Clean removes _______________ characters. (invisible)
  3. Splitting divides one column into _______________. (many)
  4. Combine merges columns into _______________. (one)
  5. Replace Values changes specific _______________ or numbers. (text)
  6. A conditional column uses an _______________ condition. (if-then)
  7. Group By summarises data by _______________. (categories)
  8. Pivot makes data _______________. (wider)
  9. Unpivot makes data _______________. (taller)
  10. Merge adds _______________ from another query. (columns)
  11. Append adds _______________ from another query. (rows)
  12. A custom column is created with a _______________. (formula)
  13. M is the _______________ behind Power Query. (language)
  14. Refresh _______________ the data. (updates)

βœ… True or False

  1. Trim removes spaces from the middle of text. (False – only beginning and end)
  2. Clean removes invisible characters. (True)
  3. Splitting a column always creates two columns. (False – can create many)
  4. Combine columns can use a separator. (True)
  5. Replace Values can only change numbers. (False – text too)
  6. Conditional columns are based on if-then logic. (True)
  7. Group By only works with numbers. (False – can count text too)
  8. Pivot makes data taller. (False – wider)
  9. Unpivot makes data wider. (False – taller)
  10. Merge combines queries side by side. (True)
  11. Append combines queries top to bottom. (True)
  12. Custom columns always use the M language. (True)
  13. Refresh deletes your data. (False – it updates)

πŸ”˜ Multiple Choice Questions

  1. Which function removes extra spaces?
    A) Clean B) Trim C) Split D) Combine
    Answer: B
  2. Which function removes invisible characters?
    A) Trim B) Clean C) Split D) Merge
    Answer: B
  3. To separate "First Last" into two columns, use:
    A) Combine B) Split C) Replace D) Group By
    Answer: B
  4. To merge "First" and "Last" into "Full", use:
    A) Split B) Combine C) Replace D) Pivot
    Answer: B
  5. Which step changes "N/A" to "0"?
    A) Replace Values B) Trim C) Clean D) Split
    Answer: A
  6. A conditional column uses:
    A) If-then B) Sum C) Average D) Count
    Answer: A
  7. Which step summarises data by categories?
    A) Pivot B) Unpivot C) Group By D) Merge
    Answer: C
  8. Pivot makes data:
    A) Wider B) Taller C) Smaller D) Messier
    Answer: A
  9. Unpivot makes data:
    A) Wider B) Taller C) Smaller D) Messier
    Answer: B
  10. Merge adds:
    A) Rows B) Columns C) Cells D) Sheets
    Answer: B
  11. Append adds:
    A) Rows B) Columns C) Cells D) Sheets
    Answer: A
  12. A custom column is created with a:
    A) Formula B) Filter C) Sort D) Pivot
    Answer: A
  13. M language is used in:
    A) Power Query B) Excel formulas C) VBA D) Word
    Answer: A
  14. Refresh does:
    A) Deletes data B) Updates data C) Sorts data D) Filters data
    Answer: B
  15. Which is not a cleaning step?
    A) Trim B) Split C) Print D) Replace Values
    Answer: C

πŸ”— Matching Exercise

Column AColumn B
1. TrimA. Remove invisible characters
2. CleanB. Divide a column
3. SplitC. Remove extra spaces
4. CombineD. Merge columns
5. Replace ValuesE. Change specific text

Answers: 1-C, 2-A, 3-B, 4-D, 5-E


πŸ“ Short Answer Questions

  1. Explain the difference between Trim and Clean.
  2. When would you use Split instead of Combine?
  3. Give an example of a conditional column.
  4. What is the advantage of using Group By?
  5. Why is it important to refresh data?

πŸ“– Scenario-based Exercises

  1. Scenario: You have a list of customer names with extra spaces and some have titles like "Mr." and "Mrs." Write steps to clean and split titles.
  2. Scenario: You have monthly sales data in separate Excel files. Describe how to append them into one query.
  3. Scenario: You have a table with product names, quantities, and prices. Create a custom column for total sales.

πŸ‘₯ Group Activity

Activity: In groups, find a messy dataset online (e.g., weather data). Load it into Power Query and apply at least 10 cleaning and transformation steps. Present your final table.


πŸ§‘ Individual Activity

Activity: Create a dataset of 20 fictional students (Name, Subject, Score). Include extra spaces, inconsistent dates, and duplicate values. Clean and transform it using Power Query.


πŸ—£οΈ Classroom Discussion Questions

  1. Why is data cleaning important in the real world?
  2. Can you think of a situation where pivot would be useful?
  3. How does Power Query save time for businesses?
  4. What would happen if you forgot to trim spaces?
  5. How can you share your Power Query knowledge with others?

πŸ› οΈ Mini Project

Project: Collect data from 10 of your classmates (Name, Age, Favourite Subject, Test Score). Clean it using Power Query: trim, split name, conditional column for pass/fail, group by subject to get average scores. Load the final report.


πŸ’» Practical Assignment

Assignment: Download a CSV file of sales data from your teacher. Load it into Power Query. Apply the following:

  1. Trim product names
  2. Clean any invisible characters
  3. Split Product Name and Category
  4. Combine First and Last Name of salesperson
  5. Replace "NULL" with 0
  6. Create a conditional column for High/Low sales
  7. Group by product to get total sales
  8. Pivot by month
  9. Refresh to test
  10. Close & Load

Submit the cleaned file.


πŸ† Challenge Exercise

Challenge: Use Power Query to get data from a web page (e.g., Wikipedia table). Clean the data: remove duplicates, split columns, and create a conditional column. Then merge it with another table you have. Show your final result.


πŸ”‘ Quiz Answers

All answers are provided within each exercise section above.


🎁 Key Takeaways

  • Advanced cleaning makes data perfect.
  • Splitting and combining help organise information.
  • Conditional columns add intelligence.
  • Grouping and pivoting summarise data.
  • Merging and appending combine sources.
  • Refresh keeps data current.

πŸ“š Preparation for Module 3

In Module 3, we will learn about Advanced Data Analysis – we will use Power Query to perform complex calculations, create dynamic reports, and automate workflows. We will also learn how to optimise queries for speed. Keep practising all the steps from Modules 1 and 2. You are doing great!


πŸŽ‰ End of Module 2 – Keep cleaning and exploring! πŸŽ‰

πŸ† Get Certified

πŸ”’

Earn this certificate

Every lesson is already free to read. Sign up, finish the lessons, pass the exam (₦2,000 or 20,000 coins), and get a verified certificate with your name on it.

πŸŽ“ Sign Up to Get Certified
πŸ› οΈ Practice Tools
Hands-on simulators & labs - subscription required.
β†’
🎯 Internship Tasks
Real-world tasks to build your portfolio - unlock them with a subscription.
β†’