VCE IT Lecture Notes by Mark Kelly, McKinnon Secondary College
Data Validation |
Types of validation
Note: Using drop-down limited lists to prevent erroneous data entry (e.g. must select state of Australia from a list rather than being allowed to type one in) is not really a validation technique which checks for invalid data : it is a tool to prevent invalid data being entered. |
ValidationChecking the reasonableness of the data before it is processed. Remember GIGO: garbage in, garbage out. Processing rubbish data gives rubbish information. If all the foremen in the factory just made up the numbers on the workers' time cards, working on the pay cheques would be totally pointless. Validation is ensuring inputted data is of the right type (e.g. numeric) and within reasonable limits (e.g. ages between 1 and 130). Databases and spreadsheets can have validation rules built into data fields to reject impossible entries. Validation can include:
Note: Validation does not check that data are accurate (e.g. that when Fred says he's 23, he actually is 23) but it can highlight suspicious entries. |
Remember: data can be valid, but inaccurate!Some definitions of data validation:
Some methods for enforcing valid data entry include: Verification - the process of entering data twice, and comparing the two entries to find differences. Aa common example of this is when you are asked to enter a new password twice to ensure it has been entered accurately. Limited lists (value lists) - Some controls that help enforce validation rules are limited lists (or value lists in Filemaker Pro talk) where the user must choose data from a list of options. This is perfect to ensure they enter only legitimate values in a form that can be understood (e.g. what state of Australia they are from). Calendar controls are good for preventing the entry of invalid dates. Note that limited lists are NOT a validation measure - they do not check for invalid data; they prevent invalid data being entered in the first place. NOTE: Don't abuse limited lists by using them where the possible entries are not actually limited e.g. If you forced users to select their title from a limited list and you offered the options of Mr, Mrs, Miss and Dr - what about professors, reverends, Ms etc? You could never guarantee you included every title in existence... and even if you DID list every title, a new one may be invented tomorrow... and your "limited" list would be so large it would be impossible to work with. BE CAREFUL ABOUT...
Remember: you validate input data, and you test output information (e.g. the answers produced by calculations, the readability of printed text) |
Back to the IT Lecture Notes index
Back to the last page you visited
Broken off the IPC page 23 August 2007
Last changed: November 23, 2011 12:02 PM
VCE IT Lecture notes copyright © Mark Kelly 2001-