Microsoft Office Tutorials and References
In Depth Information
You can determine if a column doesn’t have a value in a particular field by using the Is Null
expression. In this example, only the rows where the DateAdded field contains a Null value
will be returned.
Where DateAdded Is Null
Using the Like Operator
The Like operator is a very powerful tool that lets you search for values in a column using
wildcard characters. For instance, the following Select statement matches every customer
where the value in the Name column starts with the letters Free :
Where Name Like ’Free*’
Table 22-1 contains a list of wildcard characters that you can use with the Access database.
Remember that these characters can be used in any combination, as in the following Select
statement, which retrieves all customers whose names begin with D, E, or F:
Where Name Like ’[D-F]*’
Table 22-1. Wildcard Characters in Access
Matches zero or more characters.
True: A, AA, AB, ACC
False: B, BA
True: AA, AAA, ABA, ACCA
False: AB, AAB
True: A, AB, CAC,
False: B, BB, CCC
Matches a single character.
True: AA, AB, AC
False: AAA, BA