Finding, Filtering, Sorting  «Prev  Next»
Lesson 2 Finding data in a table
Objective Use the Find and Replace dialog box.

Finding Data in an Access Table

Sometimes you just need to find a particular piece of data within a table, perhaps you remember the name and need to find the address. The Find and Replace dialog box is the perfect solution because it allows you to search for one piece of data within one table.
To use the Find and Replace dialog box you need to know which table the data you are looking for is in. Open that table before you begin your search. The following simulation shows you how to use the Find and Replace dialog box to find the data you are looking for.

Finding a Specific Value

Although you can move to a specific record (if you know the record number) or to a specific field in the current record, usually you will want to find a certain value in a record. You can use one of these methods for locating a value in a field:
  1. Select the Find command (a pair of binoculars) from the Find group of the Ribbon.
  2. Press Ctrl+F.
  3. Use the Search box at the bottom of the Datasheet window.
The first two methods display the Find and Replace dialog box (shown in Figure 2.2). To limit the search to a specific field, place your cursor in the field you want to search before you open the dialog box. Change the Look In combo box to Current Document to search the entire table for the value.

The Find and Replace dialog box. The fastest way to activate it is to simply press Ctrl+F
Figure 2.2 The Find and Replace dialog box. The fastest way to activate it is to simply press Ctrl+F.

The Find and Replace dialog box lets you control many aspects of the search. Enter the value you want to search for in the Find What combo box, which contains a list of recently used searches. You can enter a specific value or choose to use wildcard characters.

Finding Data in Access Table

  1. If you know which field the data you are looking for is in, you can place the cursor in any record in that field. For example, if you are looking for a client named Nora: the cursor can be placed in any of the first names in the First Name field.
    Click the Next button to move to the next screen.
  2. You can display the Find and Replace dialog box in one of the following ways: Press Ctrl+F ; Click the Find button on the toolbar (it looks like binoculars); Choose Edit>>Find from the menu. The Find and Replace dialog box has a number of options, we will go through the major ones in the next few screens. Click the Next button to move to the next screen.
  3. The most important option is the Find What option: use it to type the data that you are looking for in the table. In this case we have typed “Nora.” When you type the first character in the Find What field the Find Next button becomes active. Notice that the Find What box has an arrow to it's right: You can use this drop-down list to select text that you have searched for at some other time. Go ahead and click the arrow now to see what this might look like.
    Click the Next button to move to the next screen.
  4. You can also specify where you want to look for the text within the table. The Look In drop-down list allows you to choose from the field that the cursor was in when you displayed the Find and Replace dialog box and the entire table. Click the Next button to move to the next screen.
  5. The Match option allows you to specify if the text you typed in the Find What dialog box applies to the whole field or just part of it. For instance by choosing Any Part of Field from the Match option you could find all street addressees with “Ave” in them.
    Click the Next button to move to the next screen.
  6. You can use the More button to display additional options on the Find and Replace dialog box. Three new options are displayed: The Search option, which allows you to choose which direction to search from the cursor position (Up, Down, or All); The Match Case option, which, when selected, instructs Access to find the text as typed in the Find What box, matching all uppercase and lowercase letters; and the Search Fields As Formatted option, which finds data that is in the same display format as the data as you type into the Find What box. This option is rarely used. Click the Next button to move to the next screen.
  7. As a result of your search and replace for Nora, the text, “Nora”, that you are looking for is highlighted in the table. Be warned, though, that you must move the Find and Replace dialog box so that it does not hide the table.

In the next lesson you will learn how to sort records in a table.