About object dependencies (MDB)

 Note   The information in this topic applies only to a Microsoft Access database (.mdb).

In Microsoft Office Access 2003, you can view information on dependencies between database objects (database objects: An Access database contains objects such as tables, queries, forms, reports, pages, macros, and modules. An Access project contains objects such as forms, reports, pages, macros, and modules.). Viewing a list of objects that use a specific object helps maintain a database over time and avoid errors related to missing record sources (record source: The underlying source of data for a form, report, or data access page. In an Access database, it could be a table, query, or SQL statement. In an Access project, it could be a table, view, SQL statement, or stored procedure.). For example, the Quarterly Orders query in the Sales database is no longer needed, but before deleting it, you might want to find out which other objects in the database use the query. Then, you could either modify the dependent objects to remove dependencies, or delete the dependent objects, before deleting the Quarterly Orders query. Viewing a complete list of dependent objects helps you save time and minimize errors.

In addition to viewing the list of objects that use the selected object, you can also view the objects that are being used by the selected object. For example, the following illustration shows the objects use the Quarterly Orders query, and also the tables and queries that the query uses.

Object dependencies for Quarterly Orders query

You can click on the expand (+) icon next to an object to see dependency information for that object.

Object dependencies - drilled down one level

You can navigate through up to four levels.

Access 2003 generates dependency information by searching the name maps maintained by the Name AutoCorrect (Name AutoCorrect: A feature that automatically corrects common side effects that occur when you rename forms, reports, tables, queries, fields, or controls on forms and reports. However, Name AutoCorrect cannot repair all references to renamed objects.) feature. If tracking name AutoCorrect information is turned off, you cannot view dependency information.

 Note   Tracking name AutoCorrect information must be enabled to view dependency information but performing name Autocorrect need not be enabled.

If any object is open, it must be saved and closed so that Access can generate accurate information.

The dependency information is generated only for tables (table: A database object that stores data in records (rows) and fields (columns). The data is usually about a particular category of things, such as employees or orders.), queries (query: A question about the data stored in your tables, or a request to perform an action on the data. A query can bring together data from multiple tables to serve as the source of data for a form or report.), forms (form: An Access database object on which you place controls for taking actions or for entering, displaying, and editing data in fields.), and reports (report: An Access database object that you can print, which contains information that is formatted and organized according to your specifications. Examples of reports are sales summaries, phone lists, and mailing labels.) in an Access database. It is not available for the following:

 Note   Nested queries are partially supported. Access can generate dependency information only for the outermost query. Also, the source tables and queries of a query's subdatasheet (subdatasheet: A datasheet that is nested within another datasheet and that contains data related or joined to the first datasheet.) and lookup fields (Lookup field: A field, used on a form or report in an Access database, that either displays a list of values retrieved from a table or query, or stores a static set of values.) are not listed as objects that the query depends on.

Dependency information is also not available if you don't have permissions to open an object in Design view (Design view: A view that shows the design of these database objects: tables, queries, forms, reports, and macros. In Design view, you can create new database objects and modify the design of existing objects.).

For each type of object, the following table lists the types of objects it can depend on, and the nature of dependency.

Selected object Depends on Nature of dependency
Table A table or query

A relationship (relationship: An association that is established between common fields (columns) in two tables. A relationship can be one-to-one, one-to-many, or many-to-many.) is defined between the objects.

Selected table includes the table or query as a subdatasheet.

Fields in the selected table look up values in the other object.

Table A form Fields in the selected table look up values in the form.
Query A table or query

The selected query is bound to the table or query.

A relationship is defined between the objects.

Query A form The form is referred to in the query's SQL statement.
Form A table or query

The selected form or one of its subforms is bound to the table or query.

One or more list boxes and combo boxes in the form get data from the table or query.

 Note   Dependencies that arise from a chart on a form getting data from a table or query is not included. You will have to manually identify such dependencies.

Form A form

The selected form includes the other form as a subform.

The record source of the selected form or the row source of a list box or combo box in the selected form uses a SQL statement that refers to the other form.

Report A table or query

The selected report or one of its subreports is bound to the table or query.

One or more list boxes and combo boxes in the report get data from the table or query.

 Note   Dependencies that arise from a chart on a report getting data from a table or query is not included. You will have to manually identify such dependencies.

The record source of the selected form or the row source of a list box or combo box in the selected form uses a SQL statement that refers to the other form.

Report A form

The record source of the selected report or the row source of a list box or combo box in the selected report uses a SQL statement that refers to the form.

The selected report includes the form as a subform.

Report A report The selected report includes the other report as a subreport.
 
 
Applies to:
Access 2003