CSC 300/308/402
Professor Stearns
User Input Verification


We have a clear responsibility!
If a system accepts input, incorrect input will come! Users make mistakes. Computer professionals must deal with those mistakes.

A Few Interesting Cases and Links: (thousands more exist)

Korean Air Lines 007 and American Airlines Flight 965
Interface Hall of Shame
Lask Surgery Problems
Medication Data Entry article
The Risks Digest
Therac-25 and Turner investigative report

User Input Verification is complex for several reasons:

  1. Blame game
    When systems fail due to user input, there is always much finger pointing.
    Most of the time, it is the software designer who is responsible.
    Users make mistakes; that will never change!

  2. User differences
    Some users are invested in the input; they are entering their own data and care that it is done correctly. Other users are minimum-wage data entry workers who can't wait to go home. The latter type of users have a high error rate (20% is an oft-quoted number)

  3. Range checks may be impossible
    There is no easy way to distinguish between a correctly entered grade (e.g. 84) and an incorrect grade (e.g. 81).

There are some basic principles that will increase the accuracy of user-entered data. It is rarely (never?) acceptable to assume the user will enter valid data.

  1. Enter data twice and cross check them.
    This is standard industry practice for uninvested users; make this a requirement if you are specifying a system with such users.

  2. Do type checks
    If a number is input, verify that it is a valid number.
    Specify valid numbers in the data dictionary.
    Fundamental rule: read all input as a String and convert it to the proper type. All class libraries provide conversion and error-checking code; don't do it yourself! (e.g. see the parseInt method in Java.lang.Integer).

  3. Do range checks
    This is obvious but often ignored. Be sure to specify ranges in the data dictionary. Don't forget the 8-day week story.

  4. Get human feedback
    Provide a feedback mechanism for data validation. For example, you can verify a mailing list by mailing something and asking recipients to check their data. Note the suggestion on re the Lasik Laser

  5. Confirmation Box
    Ask the user to confirm the input data. Although commonly used, such a confirmation may have little effect on accuracy because users tend to press OK spontaneously.

  6. Verify computed result
    Use the data to compute some known result; then validate the correctness and range of the result. If the computed result is bad, it is likely due to bad input.

  7. Data cleaning
    If there is a large batch input file (e.g. bank check records), it may be desirable to "clean" the input data by removing suspect records for human inspection. The purpose is to keep bad records from entering the system at all.
Final Note
Ensure that errors messages are visible, clear and non-threatening!
Use only problem-domain words! Even this Simple GUI violates the rule especially for elderly people.


Last updated on 10/2/07