Training
Certifications
Books
Special Offers
Community




 
Microsoft® Access Version 2002 Step by Step
Author Online Training Solutions, Inc.
Pages 352
Disk 1 Companion CD(s)
Level Beg/Int
Published 06/06/2001
ISBN 9780735612990
Price $29.99
To see this book's discounted price, select a reseller below.
 

More Information

About the Book
Table of Contents
Sample Chapter
Index
Related Series
Related Books
About the Author

Support: Book & CD

Rate this book
Barnes Noble Amazon Quantum Books

 


Chapter 6: Keeping Your Information Accurate



Chapter 6  Keeping Your Information Accurate

After completing this chapter, you will be able to:

  • Restrict the information entered in a database using the data type.
  • Restrict the information entered in a database using various field properties.
  • Update information in a table.
  • Delete information from a table.

Depending on how much information you have and how organized you are, you might compare a database to an old shoebox or a file cabinet, into which you toss items such as photographs, bills, receipts, and a variety of other paperwork for later retrieval. However, neither a shoebox nor a file cabinet restricts what you can place in it (other than how much you can place in it) or imposes any order on its content. It is up to you to decide what you store there and to organize it properly so that you can find it when you next need it. And neither a shoebox nor a file cabinet helps you with the task of updating your information when it changes or becomes obsolete.

When you create a database with Microsoft Access, you can set properties that restrict what can be entered in it, thereby keeping the database organized and useful. For example, The Garden Company wouldn’t want its employees to enter text into fields that should contain numbers, such as price fields. Similarly, they wouldn’t want to encourage employees to enter a long text description of something when a simple "yes" or "no" answer would work best. The field properties that control input are Required, Allow Zero Length, Field Size, Input Mask, and Validation Rule. The Required and Allow Zero Length properties are fairly obvious. If the Required property is set to Yes, the field can’t be left blank. However, if Allow Zero Length is set to Yes, you can enter an empty string (two quotation marks with nothing in between), which looks like an empty field. The other properties are more complex, so you’ll focus on them in the exercises in this chapter.


TIP:
Each property has many options. For more information about how to use properties, search for field property in Access online Help.

To ensure the ongoing accuracy of a database, you can create and run action queries that quickly update information or delete selected records from a table. For example, The Garden Company might decide to increase the price of all products in one category by some percentage, or to remove one entire product line. This type of updating is easy to do with an action query. Not only does using a query save time, but it also avoids human input errors.

The exercises in this chapter demonstrate how to use the data type and some of the field properties to restrict the data that can be entered in a table or form. It is difficult to experiment with field properties in a table that is already filled with information, because changing a field’s data type or properties can destroy or alter the data. For that reason, the first few exercises in this chapter use a new database that you will create just for the purpose of experimenting with data types and properties. Then you will resume working with sample GardenCo database files located in the following subfolders of the SBS\Access\Accurate folder: DataType, FieldSize, InputMask, ValRules, Lookup, QueryUp, and QueryDel.


Next




Top of Page


Last Updated: Saturday, July 7, 2001