Page 8 of 24PREVNEXT

Connect a form to a database

Data source in detail

Within dataFields, the data structure reflects the Access tables:
Callout 1 The Suppliers and Products tables are represented by groups, and their one-to-many relationship is maintained.
Callout 2 For each field in the Access tables there is a field in the InfoPath group.

In the data source, the dataFields group, when expanded, reflects in detail the choices you made in the data connection. You see that:

  • For each table you selected in the Access database, there is a group in the InfoPath form: the Suppliers group and the Products group.
  • For each field in the Access tables, there is a field in the InfoPath group.

For example, the SupplierID, CompanyName, and ContactName fields, among others, appear in the Suppliers table and the Suppliers group; the ProductID, ProductName, and SupplierID fields, among others, appear in the Products table and the Products group.

  • The one-to-many relationship between the Access database tables has been preserved. The Suppliers group, as primary, contains the Products group; for every supplier, there can be multiple products.

The queryFields group in the data source is included so that you may add controls to the form that are just meant for querying the database. You'll work with it later in the course.

Before moving on to the practice session, you'll need to install an Access database to connect your form to. See the next page for instructions.

Page 8 of 24PREVNEXT