Microsoft Office Tutorials and References
In Depth Information
Limiting Records with Criteria Expressions
Table 1-7 (continue d)
When Field1 Has
This Criterion . . .
You See These Records
<>15
Finds records in which Field1 is not equal to 15 .
>10 AND <20
Finds records in which Field1 is between 11 and 19 .
>=10 AND <=20
Finds records in which Field1 is 10 to 20 , inclusive.
BETWEEN 10
AND 20
Displays the same as >=10 AND <=20 .
IN
(“Virginia”,
“VA”)
Finds records in which Field1 contains either
Virginia or VA .
LIKE “A*”
Finds records in which Field1 begins with A . You can
use LIKE with wildcards, such as * , to tell Access in
general terms what you’re looking for. For more
information on the wildcards that Access recognizes, see Book II,
Chapter 5.
Using multiple criteria
Often, one criterion isn’t enough. You may want to prune the records
displayed by using multiple criteria for a single field or multiple criteria for
different fields. To get the data you want, however, you do need to know how
Access combines your criteria.
When you have criteria for only one field, decide whether you want to see
records that meet all criteria (in which case you join the criteria with AND)
or whether you want records that meet only one criterion (in which case
you join the criteria with OR). You may have three or more criteria, and you
can join them with both AND and OR.
To join criteria for a single field with AND, type them in the Criteria line of
the grid with AND between them, like this:
<5 And >65
This entry shows you records with values less than 5 as well as those with
values greater than 65.
To join multiple criteria for one field with OR, use one of these methods:
Type your expressions in the Criteria row, separating them with OR.
Type the first expression in the Criteria row, and type subsequent
expressions by using the Or rows in the design grid.
 
Search JabSto ::




Custom Search