Skip to content

Add a relation

How-to5 minPractitioner

Before you start

Add a relation when records in one module should point to a record in another, such as an invoice that belongs to a purchase order. The dialog creates the relation and a Relation field in one go.

  1. Open Modules and choose the module that holds the link, for example Invoices. The Fields page opens.
  2. Click Relation. The Add a relation dialog opens: “Link records in this module to records in another module.”
  3. In Related module, choose the module the link points to, for example Purchase Orders.
  4. In Display field, choose the field that identifies a related record, such as the purchase order number. Beezr shows it wherever the relation appears.
  5. Optional: type a Field name. Leave it empty to use the related module’s key field name.
  6. Click Create relation.

Relation added. appears, and a field of the type Relation joins the list.

The Add a relation dialog on the Invoices module, with Purchase Orders chosen as the Related module and PO Number as the Display field.
    Related module is the module the link points to.
    Display field is shown wherever the relation appears, for example the customer’s name.
    Field name is optional.
    Create relation adds the relation and the field.
  • A relation of the type One to One, with your module as master and the related module as detail. Relations: how modules connect explains both words.
  • A Relation field in your module. Its system name is the related module’s key field name in lowercase, such as purchase_order_pr_id. If a field with that name exists, Beezr adds _2, then _3.

Saving a field only adds it to the module. You place it yourself:

  1. Open Forms and drag the Relation field into a block, or click Add all. Click Save.
  2. Open Dataviews, choose Add columns on the Table tab, and pick the field. Click Save.

People then pick a record from the related module when they fill in the form.

Use the Relations manager to add a relation with the type One to Many.

Check yourself

Sara adds a relation from Invoices to Purchase Orders and leaves Field name empty. What name does the new field get?
Show the answer

The key field name of Purchase Orders, such as purchase_order_pr_id. "Leave empty to use the related module's key field name." If that name is taken, Beezr adds _2, _3 and so on.

Where do you add the new Relation field so people can pick a purchase order?
Show the answer

On the form, in the Form builder. Saving a field only adds it to the module. You place it on the form yourself.

What's next

Last checked