• Create BookmarkCreate Bookmark
  • Create Note or TagCreate Note or Tag
  • PrintPrint
Share this Page URL

Part 5. Using Access > Task 10 How to Perform a Simple Query

Task 10 How to Perform a Simple Query

Queries are a cross between filters and tables. With a query, you can quickly display a mix of fields from various tables and filter the list to display only the records you want to see. Queries can be used to edit and view your data as well as to furnish the material for forms and reports. The easiest way to create a query is to use the Simple Query Wizard. It enables you to select which fields you want to display. You can weed out fields you don't need and still see every record.

  1. Open the New Query Dialog Box

    From the Database window, select Queries in the Objects bar and double-click Create query by using wizard to open the Simple Query Wizard dialog box.

  2. Select Fields

    From the Tables/Queries drop-down list, select the table. Select a field you want included in the query table results and click the > button to add it to your query. Select as many fields from as many different tables as you want and click Next. In this example, I want to create a simple query that lists customers in Indiana—their names and phone numbers—which are fields in my Customers table. If I wanted to include details about recent invoices, I'd have to pull fields from the Invoices table as well.

  3. Give the Query a Name

    Type a name for the query and click Finish to create your query, which appears in table form. (To filter the records that appear in the query, click Modify the query design before you click Finish.)

  4. Filter the Query

    If you decided to filter the query (to display only customers from Indiana, for example), enter the criteria you want in the datasheet that appears. To filter on a field that isn't in the query, select the field from an empty column's drop-down list (click in the Field box, and the drop-down list button appears), enter the criteria, and remove its check mark.

  5. Run the Query

    To display the results of your query, click the Run Query button on the toolbar.

  6. Query Results

    Access displays the records, showing only the fields you specified. To close the query, click the window's Close button.



Not a subscriber?

Start A Free Trial

  • Creative Edge
  • Create BookmarkCreate Bookmark
  • Create Note or TagCreate Note or Tag
  • PrintPrint