Microsoft Office Tutorials and References
In Depth Information
Session 3.1
When you save the query, all of your design changes—including the selection of the sort
fields—are saved with the query. The next time Matt runs the query, the records will
appear sorted by the primary and secondary sort fields.
9. Click the Save button
on the Query Datasheet toolbar to save the revised
EmployerPositions query.
Matt recently spoke with a recruit who is interested in clerk positions that are available
in New Hampshire. So, Matt wants to concentrate on records that match those criteria.
Selecting only the records with a PositionTitle field value that contains the word “Clerk”
and a StateProv field value of “NH” is a temporary change that Matt wants in the
datasheet, so you do not need to switch to Design view and change the query. Instead,
you can apply a filter.
Filtering Data
A filter is a set of restrictions you place on the records in an open datasheet or form to
temporarily isolate a subset of the records. A filter lets you view different subsets of dis-
played records so that you can focus on only the data you need. Unless you save a query
or form with a filter applied, an applied filter is not available the next time you run the
query or open the form.
The simplest technique for filtering records is Filter By Selection. Filter By Selection lets
you select all or part of a field value in a datasheet or form, and then display only those
records that contain the selected value in the field. Another technique for filtering records
is to use Filter By Form , which changes your datasheet to display empty fields. Then you
can select a value from the list arrow that appears when you click any blank field to apply
a filter that selects only those records containing that value.
Reference Window
Using Filter By Selection
In the datasheet or form, select all or part of the field value that will be the basis for
the filter.
Click the Filter By Selection button on the toolbar.
For Matt’s request, you first need to select just the word “Clerk” in the PositionTitle
field, and then use Filter By Selection to display only those query records with this same
partial value. Then you will filter the records further by selecting only those records with a
value of “NH” in the StateProv field.
To display the records using Filter By Selection:
1. In the query datasheet, locate the first occurrence of a PositionTitle field containing the
word “Clerk,” and then select Clerk in that field value.
2. Click the Filter By Selection button on the Query Datasheet toolbar. Access displays
the filtered results. Only the 10 query records that have a PositionTitle field value contain-
ing the word “Clerk” appear in the datasheet. The status bar’s display (FLTR), the area next
to the navigation buttons, and the selected Remove Filter button on the toolbar all indicate
that the records have been filtered. See Figure 3-18.
 
Search JabSto ::




Custom Search