Choosing a data type for a value
Pick the data type by what you will do with the value: calculate (number), sort by date (date/time), test true or false (Boolean). Postcodes are text, not numbers, as you never do maths on them.
Understanding Choosing a data type for a value in VCE Data Analysis
What it does: A date/time type lets a system sort and compare values by time, which plain text cannot do correctly. Yes/no values are tested as true or false, so Boolean is the type that matches how the value is used. Postcodes are labels, not quantities. Stored as an integer, 0800 would lose its leading zero and become 800. Prices with cents have decimal places, so floating point is used. An integer would drop the cents and give wrong totals. A value made of digits is not always a number. Phone numbers and postcodes look numeric but are never used in calculations, so they are text.
Common mistakes: Postcodes are never used in calculations, so they should be Text. An Integer drops leading zeros (0800 becomes 800). The line should be Postcode : Text. InStock is tested as true or false, so it should be Boolean. Text would let any word be stored and makes true/false tests unreliable. It should be InStock : Boolean.
Free printable worksheet with full answer key — or add this module to a class and your students practise it interactively.
This module's key terms are also in a printable crossword (Modules 15–24) and word search (Modules 3–24).
Take this worksheet further — free with Cloodit
Each concept is reinforced from every angle — learned, then applied, then tested.
Cloodit turns curriculum-aligned coding content into journeys students work through one biome at a time.
Over 100 of them, across seven natural biomes.
Turns their work into revision material ready for Flash Cards and Exam study.
Live, competitive practice for the start of the lesson or a teacher-led lesson finisher.
Honour your top performers, or encourage a student who's trying hard — ready to print in seconds.
Quick Questions
Match the Pairs
Key Term
data typeFill in the Blanks
Spot the Error
Student with a class code? Join your class →