Hiring Partners
Segilola Resources Operating LimitedTaviatech TechnologiesFCMBMTN NigeriaAdvans La Fayette Microfinance BankAboki AfricaFirst Bank of NigeriaOPay
โ† Data Cleaning in Excel ยท Lesson 8 of 9

Module Seven

๐Ÿ“– 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.
8
Module 7: Advanced Excel Data Cleaning Techniques

Module 7: Advanced Excel Data Cleaning Techniques

Introduction

So far, you have learned how to remove duplicates, correct missing information, clean text, format dates and numbers, sort records, and use filters.

But what happens when you have thousands of rows of information? Cleaning each row manually can take a lot of time.

Microsoft Excel provides advanced tools and functions that help you clean large amounts of data more quickly and accurately.

In this module, you will learn how to use Flash Fill, Find and Replace, Text to Columns, conditional formatting, Excel Tables, and useful formulas to identify and correct data problems.

Learning Objectives

By the end of this module, you should be able to:

  • Use Flash Fill to recognise and complete data patterns.
  • Use Find and Replace to correct repeated mistakes.
  • Separate information using Text to Columns.
  • Highlight unusual or incorrect entries with Conditional Formatting.
  • Use formulas to identify data problems.
  • Convert ordinary data ranges into Excel Tables.
  • Combine different cleaning techniques in one worksheet.

1. Using Flash Fill to Clean Data

Flash Fill is an Excel feature that recognises a pattern in your data and automatically fills the remaining cells using that pattern.

Imagine you have a list of students with their first names and surnames in one column. You want to separate the first names. Instead of typing every name manually, you can use Flash Fill.

Example

Full Name First Name
Adeola JohnsonAdeola
Chinedu Okafor
Fatima Bello
David Williams

How to Use Flash Fill

  1. Enter Adeola in the first cell under First Name.
  2. Move to the next empty cell in the same column.
  3. Go to the Data tab.
  4. Click Flash Fill.
  5. Excel will try to recognise the pattern and fill the remaining names.

You can also use the keyboard shortcut Ctrl + E on Windows.

Remember: Always check the results after using Flash Fill. Excel may misunderstand a pattern if the information is not consistent.

2. Using Find and Replace

Find and Replace helps you locate repeated words, numbers, or characters and replace them with the correct information.

Imagine a company has entered the word "Lagos" incorrectly as "Lagoss" in 200 customer records. Correcting each entry manually would take time.

Find and Replace can help you locate and correct the repeated error.

How to Use Find and Replace

  1. Open your Excel worksheet.
  2. Press Ctrl + H on your keyboard.
  3. Enter the incorrect word in the Find what box.
  4. Enter the correct word in the Replace with box.
  5. Click Replace All to correct all matching entries.

Example

Incorrect Entry Correct Entry
LagossLagos
Ibadan CityyIbadan City
AbujjaAbuja
Important: Be careful when using Replace All. Check that the replacement will not change correct information. It is a good idea to make a backup copy before replacing many entries.

3. Separating Information with Text to Columns

Sometimes, different pieces of information are stored together in one cell. Text to Columns helps you separate them into different columns.

For example, a customer database may store full names in one column. You may want to separate first names and surnames.

Example

Full Name
Samuel Adeyemi
Mary Johnson
Chuka Okafor

How to Use Text to Columns

  1. Select the column containing the full names.
  2. Open the Data tab.
  3. Click Text to Columns.
  4. Choose Delimited.
  5. Click Next.
  6. Select Space as the delimiter.
  7. Click Next and choose the destination if necessary.
  8. Click Finish.

Excel will separate the names at the spaces and place the results into different columns.

Other Uses: Text to Columns can also separate information divided by commas, semicolons, tabs, or other characters.

4. Using Conditional Formatting to Find Data Problems

Conditional Formatting changes the appearance of cells when they meet conditions you choose. It can help you identify unusual values quickly.

Imagine a teacher wants to identify examination scores below 40. Instead of checking every score manually, the teacher can highlight those scores automatically.

How to Highlight Scores Below 40

  1. Select the cells containing examination scores.
  2. Open the Home tab.
  3. Click Conditional Formatting.
  4. Choose Highlight Cells Rules.
  5. Select Less Than.
  6. Enter 40.
  7. Choose a formatting style.
  8. Click OK.

Excel will highlight all scores below 40 using the selected style.

Other Ways to Use Conditional Formatting

  • Highlight duplicate values.
  • Highlight numbers greater than a selected value.
  • Highlight dates within a particular period.
  • Use colour scales to compare high and low values.
  • Highlight blank cells using a formula-based rule.
Important: Conditional Formatting helps you spot possible problems. It does not automatically correct the data. Always investigate highlighted records before making changes.

5. Using Excel Formulas to Check Data

Excel formulas can help you find missing information, check text length, remove extra spaces, and identify unusual entries.

A. Using COUNTBLANK

COUNTBLANK counts the number of empty cells in a selected range.

Formula:

=COUNTBLANK(A2:A20)

This formula counts all empty cells between A2 and A20.

B. Using LEN

LEN counts the number of characters in a cell. It is useful when checking phone numbers, identification codes, or other information that should have a fixed length.

Formula:

=LEN(A2)

If cell A2 contains 08012345678 stored as text, LEN returns 11. If it returns a different number, you may need to investigate the entry.

C. Using TRIM

TRIM removes unnecessary spaces from text, including extra spaces between words.

Formula:

=TRIM(A2)

For example, " Mary Johnson " becomes "Mary Johnson".

D. Using IF

IF checks whether a condition is true or false and returns a result based on that condition.

Formula:

=IF(B2>100,"Check Score","Valid")

If the score in B2 is greater than 100, Excel displays Check Score. Otherwise, it displays Valid.

E. Using ISBLANK

ISBLANK checks whether a cell is empty.

Formula:

=IF(ISBLANK(A2),"Missing Information","Available")

This formula displays Missing Information if A2 is empty. Otherwise, it displays Available.

6. Converting Data into an Excel Table

An Excel Table makes information easier to organise, filter, format, and manage. It is especially useful when working with large datasets.

How to Create an Excel Table

  1. Select your data, including the column headings.
  2. Press Ctrl + T on your keyboard.
  3. Check the My table has headers option if your data has headings.
  4. Click OK.

Excel will convert your selected information into a table. Dropdown filter arrows will appear beside the headings.

Benefits of Excel Tables

  • They make filtering and sorting easier.
  • They automatically extend when you add new rows.
  • They provide consistent formatting.
  • They make formulas easier to manage.
  • They help organise large amounts of information.

7. Combining Advanced Cleaning Techniques

In real projects, you may need to use several Excel tools together. No single tool can solve every data problem.

Imagine a training company in Nigeria has collected information from 1,000 learners. The records contain:

  • Names with unnecessary spaces.
  • Repeated spelling mistakes.
  • Full names stored in one column.
  • Missing phone numbers.
  • Incorrect examination scores.
  • Different date formats.

A Suggested Cleaning Process

  1. Make a backup copy of the original spreadsheet.
  2. Use TRIM to remove unnecessary spaces.
  3. Use Find and Replace to correct known repeated spelling errors.
  4. Use Text to Columns to separate full names where appropriate.
  5. Use Flash Fill to complete recognised patterns.
  6. Use COUNTBLANK and ISBLANK to locate missing information.
  7. Use LEN to check phone number lengths.
  8. Use Conditional Formatting to highlight suspicious scores.
  9. Use Data Validation to prevent future incorrect entries.
  10. Convert the cleaned dataset into an Excel Table.
Real-World Example: A business in Ibadan can use these techniques to clean its customer database before sending marketing messages or preparing sales reports. Clean customer records help reduce mistakes and improve communication.

8. Practical Exercise

You have been asked to clean a small learner database for CRMNuggets. The information below contains several data problems.

Full Name Phone Number Score
Adeola Johnson 0801234567885
Mary Bello0801234567110
Chinedu Okafor72
Fatima Yusuf0812345678945
David Williams0809876543295

Your Tasks

  1. Use TRIM to remove unnecessary spaces from names.
  2. Use Text to Columns to separate first names and surnames.
  3. Use LEN to check the length of each phone number.
  4. Use COUNTBLANK to find missing phone numbers.
  5. Use an IF formula to identify scores above 100.
  6. Use Conditional Formatting to highlight scores below 50.
  7. Convert the cleaned information into an Excel Table.
Challenge: Create a new column called Data Status. Use Excel formulas to identify records with missing phone numbers or scores above 100. Display a suitable message for each record.

Module Summary

In this module, you have learned how to:

  • Use Flash Fill to complete data based on patterns.
  • Use Find and Replace to correct repeated mistakes.
  • Separate information with Text to Columns.
  • Use Conditional Formatting to highlight suspicious values.
  • Use COUNTBLANK, LEN, TRIM, IF, and ISBLANK formulas.
  • Convert ordinary data ranges into Excel Tables.
  • Combine different techniques to clean larger datasets.

Module Assessment

Question 1

Which Excel feature automatically fills information based on a recognised pattern?

  1. Flash Fill
  2. Filter
  3. Sort
  4. Print

Question 2

Which keyboard shortcut opens Find and Replace?

  1. Ctrl + P
  2. Ctrl + H
  3. Ctrl + T
  4. Ctrl + E

Question 3

Which Excel tool separates information stored together in one column?

  1. Conditional Formatting
  2. Text to Columns
  3. Data Validation
  4. Freeze Panes

Question 4

Which formula counts empty cells in a selected range?

  1. LEN
  2. TRIM
  3. COUNTBLANK
  4. SUM

Question 5

What does the TRIM function do?

  1. Adds numbers
  2. Removes unnecessary spaces from text
  3. Deletes entire rows
  4. Changes dates

Question 6

Which function counts the number of characters in a cell?

  1. LEN
  2. IF
  3. COUNTBLANK
  4. MAX

Question 7

Which Excel feature can highlight scores below 40 automatically?

  1. Text to Columns
  2. Conditional Formatting
  3. Flash Fill
  4. Find and Replace

Coming Up in Module 8

You are almost at the end of this course! In the final module, you will complete a practical data cleaning project. You will work with a dataset, identify problems, apply the techniques you have learned, and produce a cleaner spreadsheet.

Keep practising. Data cleaning is an important skill for anyone who wants to work with Excel, data analysis, or business information.

๐Ÿ† 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.
โ†’