If an event form has an Embedded event in it, you can use the Embedded event summary field to extract a value from the Embedded event.
This is useful when you want to perform calculations using data from the records that are associated with the current record.
For example, the illness event form in the screenshot above contains an Embedded event for prescribed medications. Each medication that is prescribed as a result of a specific illness incident is entered into a medication form via the relevant illness record.
To show the most recently prescribed medication for each illness instance, an Embedded event summary field extracts the medication name from the embedded event.
If you were using a linked text calculation, the result would be the most recently prescribed medication for all of that person’s illnesses.
If a new medication is prescribed for the illness, the illness record will need to be saved to update the Embedded event summary field value.
Steps to build an embedded event summary field
- Log in to the builder interface.
- Select the Event forms tool.
- Choose an event form that contains an Embedded event.
- Add an Embedded Event Summary field from the calculations menu.
- Name the field.
- Use the Calculation tab to enter the name of the field within the Embedded event that you want to summarize. Note that the field name must be entered here exactly how it’s written in the event form that’s embedded.
- Save the event form.
- Test this form on the main interface. Remember that you’ll need to have data permissions for the event form you’ve embedded as well as the form you’ve just added the Embedded event summary field to.
The Embedded event must have the advanced property called Show date column set to Yes for the Embedded event summary field to work.