Using the Replace Feature

Team-Fly    

 
10 Minute Guide to Microsoft Access 2002
By Joe Habraken
Table of Contents
Lesson 15.  Searching for Information in Your Database

Using the Replace Feature

The Replace feature is similar to the Find feature, except that you can stipulate that a value, which you specify, replace the data found during the search. For example, if you found that you misspelled a brand name or other value in a table, you could replace the word with the correct spelling. This is useful for correcting proper names because the Spelling Checker doesn't help correct those types of spelling errors.

To find and replace data, follow these steps:

  1. Select Edit, Replace , or press Ctrl+H . The Find and Replace dialog box appears with the Replace tab displayed (see Figure 15.3).

    Figure 15.3. You can find specific text in a table and then replace it using the Replace feature.

  2. Type the text you want to find into the Find What text box.

  3. Type the text you want to replace it with into the Replace With text box.

  4. Select any options you want using the Match drop-down list or the check boxes on the Search tab. They work the same as the options discussed on the Find tab (in the previous section).

  5. To start the search, click Find Next . Access finds the first occurrence of the search string.

  6. Click the Replace button to replace the text.

  7. Click Find Next to find other occurrences, if desired, and replace them by clicking the Replace button.

  8. If you decide that you would like to replace all occurrences of the search string in the table, click the Replace All button.

  9. When you have found the last occurrence of the search string (Access lets you know that the string can no longer be located, which means you are at the end of the table), click the Close ( X ) button on the Find and Replace dialog box.

The Find and Replace feature works well when you want to work with data in a particular field, but it is limited because you can work with only one record at a time. Other, more sophisticated ways exist to locate records that contain a particular parameter. For example, you can filter records (discussed in the next lesson) using a particular field's content as the filter criteria. This provides you with a subset of the current table, showing you only the records that include the filter criteria.

Queries also provide you with a method for creating a subset of records found in a database table. Queries are discussed in Lesson 17, "Creating a Simple Query," and Lesson 18, "Creating Queries from Scratch."

In this lesson, you learned how to find and replace data in a database. In the next lesson, you learn how to sort , filter, and index records in a database table.


Team-Fly    
Top
 


10 Minute Guide to Microsoft Access 2002
10 Minute Guide to Microsoft Access 2002
ISBN: 0789726319
EAN: 2147483647
Year: 2000
Pages: 160
Authors: Joe Habraken

flylib.com © 2008-2017.
If you may any questions please contact us: flylib@qtcs.net