Skip to content

Mission 3: Column Types

Learning Objective

Understand what column types are and how to ensure they are set correctly for meaningful data analysis.


Background

Setting correct column types is essential for meaningful results. For example:

  • To calculate the average value of a column, we need numeric types such as whole numbers, decimals, or fixed decimal numbers
  • For text data, we use the text type
  • For dates and times, we use date/datetime types

Choosing the right column type ensures that operations like calculations, sorting, and filtering work correctly.


Dataset

Download the required dataset: business_transaction.xlsx


Understanding the Data Table Structure

The Header Row

Looking at the table, you'll see the first row with column names at the top. This is called the header.

Header Row

The header is enclosed in the red box

Data Types

Right above the header, you'll see the data types for each column.


Common Column Types

Whole Number

If a column contains only numbers without decimals, the data type should be whole number.

Whole Number Column

A column of type whole number - appropriate since no decimals are used

Text

For columns containing letters, numbers, and other characters, use the text type.

Text Column

A column of type text - appropriate for mixed character data

Best Practices

  • Review data types after importing data to ensure they're set correctly
  • Numeric data should use whole number or decimal types, not text
  • Dates should use date/datetime types for proper sorting and filtering
  • Mixed content (letters and numbers) typically requires text type

Summary

You've successfully learned:

✓ What column types are and why they matter

✓ How to identify the header and data types in a table

✓ Common column types (whole number, decimal, text, date)

✓ Best practices for choosing appropriate column types


Well done! Now let's move on to the next mission!