## Working with databases

This section introduces several common procedures related to accessing database files from within Seagate Crystal Reports. Where practical, step-by-step instructions are provided.

### Using Access queries

#### Opening Access queries through DAO

Microsoft Access queries can be used in Seagate Crystal Reports as separate data sets, just like Access tables. When you open an Access database through the DAO engine (see Microsoft Access), any queries in the database can automatically be read.

###### To open an Access query through DAO

1. On the Standard toolbar, click `New`.

   The Seagate Crystal Report Gallery appears.

2. Click `As a Blank Report` and then `OK`.
3. In the Data Explorer dialog box, locate, highlight, and then expand the Microsoft Access database (*.mdb) file that contains the query you want to use in your report.

   Note: If your database requires a user name and password, or any other log on information, a log on dialog box appears.

4. Highlight the query and any tables you want to include in your report and click `Add`.
5. Click `Close` when you are finished with the Data Explorer dialog box.

   The Field Explorer dialog box appears with Database Fields selected and expanded.

   Note: The Visual Linking Expert dialog box appears first if you have selected several queries and tables.

   All of the queries and tables you highlighted from your Access database appear in the Field Explorer dialog box.

6. Locate your query in the `Database Fields` list, and double-click its name.

   The query expands to display all the fields it contains.

7. Highlight any fields you want to use in your report and add them to the Design tab.

Note: You cannot use Access Action queries or Update queries in Seagate Crystal Reports. However, you can use Access Select queries and Cross-tab queries.

Seagate Software, Inc. http://www.seagatesoftware.com Please send comments to: techpubs@seagatesoftware.com