Next Post

How to Design a Query

Under the Microsoft Access View menu, point to Database Objects, and then select Queries. See the example below.

how to design a query

The ‘Show Table’ screen will appear similar to the example below with a list of tables in the database. Select the table name and click on the ‘Add’ button.

Repeat the steps above for each table to include in your query.

When all of the tables have been selected, click on the ‘Close’ button to close the ‘Show Table’ screen.

show a table

The following screen will appear. Both the Author and Book tables have been selected and will now appear in the top half of the query design window.

Query table without data

Go to the book’s table field list in the top half of the query design window. Double-click each field to add the following fields: BookID, BookName, AuthorID.

In the Author table field list in the top half of the query design window, double-click the *. Clicking on the * is the equivalent of selecting all the fields from a particular table.

The query design window should appear similar to the following example.

query table with data

In order to save the query, click the (Save) button on the Quick Access Toolbar at the top of the screen. A ‘Save As’ pop up box will appear that will ask for the Query Name. In the example below, the query has been named qryBookAuthor (it is common to preface your query name with the words ‘qry’.)

save query table

The newly named query now appears as ‘qryBookAuthor’ under the Queries Objects.

created query

Double-click on the Query (eg. qryBookAuthor) or click ‘Run’ from the Design Tab to view the results of the query.

details displayed in database

How To Add Criteria to Your Query >

By Admin at 17 Nov 2015, 16:27 PM



Post a comment

Please correct the following: