eHow launches Android app: Get the best of eHow on the go.

How To

How to Create "AND" or "OR" Operators with Microsoft Access

Member
By The Armchair Geek
User-Submitted Article
(0 Ratings)
Create "AND" or "OR" Operators with Microsoft Access
Create "AND" or "OR" Operators with Microsoft Access
Logo of MS Access

If you use Microsoft Office Access, you may want to create queries that match several conditions. The AND operator narrows your query by making it more restrictive. For example, you can filter employees from the Finance Department AND Public Relations Department. The OR operator makes your query more broad, allowing more records to match. For example, you can filter employees from the Finance Department OR Public Relations Department. Using operators on Microsoft Office Access is very easy. All you need is a basic understanding of queries.

Difficulty: Moderately Easy
Instructions
  1. Step 1

    The first thing you need to do is open the Customer’s List query in Design view. You can open any database object in Design view by simply selecting the object and click the Design button in the Database window. For example, let’s say you want to find which of your customers are from the Finance Department AND the Public Relations Department. You will need to create an AND query by simply listing the criteria on the same line. The ContactTitle field must be equal to the Owner and Department field.

  2. Step 2

    Click the ContactTitle column’s Criteria row. Type Owner. This will retrieve any records where the ContactTitle equals “Owner.” Now you have to enter the Department criteria.

  3. Step 3

    Click the Department column’s Criteria row and type in Finance. Because you entered the Department criteria in the same Criteria row as the ContactTitle criteria, Microsoft Access will treat this query as an AND statement.

  4. Step 4

    Now you need to click the View button on your toolbar. Access will now display the results of the query. All the results will match the query. The records have “Owner” in the ContactTitle field and “Finance” in the Department field.

  5. Step 5

    To create an OR statement, click the Design view by selecting the View button on the toolbar.

  6. Step 6

    Delete the “Owner” criteria from the ContactTitle row. Now you want to create a query to find customers from the Finance Department OR the Public Relations department.

  7. Step 7

    In the Department column, click the second Criteria row and type Public Relations. Because the criteria was entered in a different row, Access will treat the query as an OR statement.

  8. Step 8

    Click the View button on your toolbar to see the results of your query. Access will list all employees from the Finance Department OR the Public Relations Department.

    Click Save to save your work and close the query window.

Subscribe

Post a Comment

Post a Comment

Related Ads

  • Have you done this? Click here to let us know.
I Did This
Get Free Computers Newsletters

Copyright © 1999-2009 eHow, Inc. Use of this web site constitutes acceptance of the eHow Terms of Use and Privacy Policy.   en-US Portions of this page are modifications based on work created and shared by Google and used according to terms described in the Creative Commons 3.0 Attribution License.

eHow Computers
eHow_eHow Technology and Electronics