Skip to content
Contact: contact@himforward.com
← Full course outline

MODULE 2 · LESSON 2.3

Sorting, Filtering and Data Validation

Estimated time: 25 minutes

2.3.1 What is sorting?

Sorting means arranging data in a particular order.

  • Facility names alphabetically.
  • Patient counts from smallest to largest.
  • Reporting dates from oldest to newest.
  • Indicator values from highest to lowest.
Before sorting
FacilityPatients
Central Clinic120
Riverside Clinic95
Hilltop Clinic110
Patient column sorted from largest to smallest. The facility names stay attached to their values.
FacilityPatients
Central Clinic120
Hilltop Clinic110
Riverside Clinic95

2.3.2 What is filtering?

Filtering allows you to display only the records that meet particular conditions.

Imagine you have reports for 20 facilities but want to see only those reporting in February. You can filter the Month column to display February records.

  • One particular facility.
  • Records with missing values.
  • Facilities reporting zero cases.
  • Reports from a particular local government area.

Filtering does not necessarily delete the other records. It temporarily hides records that do not meet the selected conditions.

If you filter Month to February, only these two rows remain visible.
FacilityMonthPatients
Central ClinicFebruary135
Riverside ClinicFebruary100

2.3.3 What is data validation?

Data validation helps control what users can enter into a cell.

Suppose you are designing a spreadsheet for monthly facility reports. You want to prevent users from entering an impossible number of patients, using inconsistent facility names or selecting an invalid reporting month.

  • Restricting a numeric field to non-negative whole numbers.
  • Providing a drop-down list of approved facility names.
  • Restricting dates to an acceptable period.
  • Requiring a value to fall within a defined range.

Validation rules do not guarantee that every entry is correct. A plausible number can still be inaccurate, and a valid entry can still describe the wrong facility or reporting period.

2.3.4 A simple data validation example

Suppose a worksheet has a column called Patients Attended. You want the entries to be whole numbers greater than or equal to zero.

  1. Select the cells where patient counts will be entered.
  2. Open the Data tab.
  3. Select Data Validation.
  4. Choose a whole-number restriction.
  5. Set the minimum value to zero.
  6. Save the rule.

The exact menu layout may vary by Excel version. You can also create a drop-down list of approved facility names to reduce inconsistent spelling.

Lesson 2.3 exercise

Suggested answers

  1. What is the difference between sorting and filtering?
  2. If you want to see only February reports, which feature would you use?
  3. Why should you use an approved list of facility names?
  4. Does data validation guarantee that all data is correct?