Source: https://vaultcrmhelp.veeva.com/doc/Content/CRM_topics/Events/EventBusinessRules/AttdRulesExample.htm

## Examples of Attendance Rules

This topic contains detailed examples for each type of Event Attendance Rule.

[![Closed](../../../../Skins/Default/Stylesheets/Images/transparent.gif)Per Attendee Attendance Limit Rules](#)

#### Limit for Single Event Type

The admin wants to restrict the number of Lunch and Learns about the same topic a Professional-type attendee can be invited to in a 90 day period.

To implement this restriction:

1. Navigate to the **Event Business Rules** tab.
2. Create an Event Business Rule with an object type of **Per Attendee Attendance Limit Rule**.
3. Populate the following fields:

   | Field | Value |
   | --- | --- |
   | name\_\_v | Attendee Limits |
   | run\_rule\_event\_action\_\_v | submit\_for\_approval\_\_v |
   | attendee\_account\_type\_\_v | professional\_\_v |
   | attendee\_status\_\_v | ;;approved\_\_v:invited\_\_v,accepted\_\_v;;closed\_\_v:attended\_\_v,signed\_\_v;; |
   | global\_rule\_\_v | Unselected |
   | warning\_type\_\_v | Hard Warning |
   | warning\_text\_\_v | EM\_RULE\_PER\_ATTENDEE\_ATTENDANCE;;EVENT\_BUSINESS\_RULE\_WARNING  (Populated automatically) |
   | per\_event\_topic\_\_v | Selected |
   | date\_threshold\_type\_\_v | Rolling |
   | rolling\_period\_\_v | 90 |
4. Select **Save**.

After creating the Event Business Rule, associate the rule to the appropriate Event Type and Country:

1. Navigate to the **Attendee Limits** record.
2. Navigate to the **Event Business Rule Configurations** related list.
3. Select **New**.
4. Create an **Event Business Rule Configuration** record with the following values:

   | Field | Value |
   | --- | --- |
   | event\_business\_rule\_\_v | Attendee Limits  (Populated automatically) |
   | event\_type\_\_v | lunch\_and\_learn\_\_v |
   | country\_\_v | United States |
   | rule\_start\_date\_\_v | January 1, 2020 |
   | rule\_end\_date\_\_v | December 31, 2050 |
   | limit\_quantity\_\_v | 3 |

An event organizer schedules a lunch and learn about the product Cholecap and attempts to invite Clinton Ackerman as an attendee. However, Clinton Ackerman attended one lunch and learn about Cholecap two weeks ago and had already been invited to two more lunch and learns about Cholecap in the coming weeks. When the event is submitted for approval, the following hard warning displays:

Clinton Ackerman has or will attend 3 United States Lunch and Learn events. Attendees cannot attend more than 3 events.

The event cannot proceed to further stages of planning until Clinton Ackerman is removed as an attendee.

#### Limit for Multiple Event Types

After creating a limit for single event types, the admin decides they want to also restrict the number of Speaker Programs and Congress type events about the same topic a Professional-type attendee can be invited to in a 90 day period.

They do not need to create an Event Business Rule record and can instead use the Attendee Limits record from the previous example. To implement these additional restrictions, create two Event Business Rule Configurations with the following values:

| Field | Speaker Program Record | Congress Record |
| --- | --- | --- |
| event\_business\_rule\_\_v | Attendee Limits  (Populated automatically) | Attendee Limits  (Populated automatically) |
| event\_type\_\_v | speaker\_program\_\_v | congress\_\_v |
| country\_\_v | United States | United States |
| rule\_start\_date\_\_v | January 1, 2020 | January 1, 2020 |
| rule\_end\_date\_\_v | December 31, 2050 | December 31, 2050 |
| limit\_quantity\_\_v | 4 | 2 |

An event organizer schedules a Congress about the product Cholecap and invites both Bob Adams and Clinton Ackerman before submitting the event for approval. Bob Adams has only been invited to one other Congress in the 90 days before and after the event. Clinton Ackerman has been invited to three Congresses in the same time period, but none of them were about Cholecap.

Both attendees are allowed to be invited to the newly created Congress.

#### Limit for Single Event Type Across All Event Topics and Countries

For compliance reasons, the admin needs to restrict the number of Speaker Programs a Professional-type attendee can be invited to for all topics over the course of the calendar year. Additionally, the admin wants this restriction to apply to all countries in the instance.

To implement this restriction:

1. Navigate to the **Event Business Rules** tab.
2. Create an Event Business Rule with an object type of **Per Attendee Attendance Limit Rule**.
3. Populate the following fields:

   | Field | Value |
   | --- | --- |
   | name\_\_v | Yearly Attendee Limit |
   | run\_rule\_event\_action\_\_v | submit\_for\_approval\_\_v |
   | attendee\_account\_type\_\_v | professional\_\_v |
   | attendee\_status\_\_v | ;;approved\_\_v:invited\_\_v,accepted\_\_v;;closed\_\_v:attended\_\_v,signed\_\_v;; |
   | global\_rule\_\_v | Selected |
   | warning\_type\_\_v | Hard Warning |
   | warning\_text\_\_v | EM\_RULE\_PER\_ATTENDEE\_ATTENDANCE;;EVENT\_BUSINESS\_RULE\_WARNING  (Populated automatically) |
   | per\_event\_topic\_\_v | Unselected |
   | date\_threshold\_type\_\_v | Calendar Year |
4. Select **Save**.

After creating the Event Business Rule, associate the rule to the appropriate Event Type and Country:

1. Navigate to the **Yearly Attendee Limit** record.
2. Navigate to the **Event Business Rule Configurations** related list.
3. Select **New**.
4. Create a Event Business Rule Configuration record with the following values:

   | Field | Value |
   | --- | --- |
   | event\_business\_rule\_\_v | Yearly Attendee Limit  (Populated automatically) |
   | event\_type\_\_v | speaker\_program\_\_v |
   | rule\_start\_date\_\_v | January 1, 2020 |
   | rule\_end\_date\_\_v | December 31, 2050 |
   | limit\_quantity\_\_v | 10 |
5. Select **Save**.

An event organizer schedules a speaker program and adds Bob Adams as an attendee. Bob Adams has already attended seven speaker programs this calendar year and is already invited to three more before the calendar year is over.

When the event is submitted for approval, the following hard warning displays:

Bob Adams has or will attend 10 United States Speaker Program events. Attendees cannot attend more than 10 events.

The event cannot proceed to further stages of planning until Bob Adams is removed as an attendee.

[![Closed](../../../../Skins/Default/Stylesheets/Images/transparent.gif)Cross-Event Per Attendee Attendance Limit Rules](#)

#### Rolling Period Limit Across All Topics

The admin wants to restrict how many events a Professional-type attendee can be invited to during a rolling 180 day period.

To implement this restriction:

1. Navigate to the **Event Business Rules** tab.
2. Create an Event Business Rule with an object type of **Cross-Event Per Attendee Attendance Limit Rule**.
3. Populate the following fields:

   | Field | Value |
   | --- | --- |
   | name\_\_v | Cross-Event Attendee Limits |
   | run\_rule\_event\_action\_\_v | submit\_for\_approval\_\_v |
   | limit\_quantity\_\_v | 10 |
   | attendee\_account\_type\_\_v | professional\_\_v |
   | attendee\_status\_\_v | ;;approved\_\_v:invited\_\_v,accepted\_\_v;;closed\_\_v:attended\_\_v,signed\_\_v;; |
   | global\_rule\_\_v | Unselected |
   | warning\_type\_\_v | Soft Warning |
   | warning\_text\_\_v | EM\_RULE\_CROSSEVENT\_PER\_ATTENDEE\_ATTENDANCE;;EVENT\_BUSINESS\_RULE\_WARNING  (Populated automatically) |
   | comment\_required\_\_v | Required |
   | per\_event\_topic\_\_v | Unselected |
   | date\_threshold\_type\_\_v | Rolling |
   | rolling\_period\_\_v | 180 |
4. Select **Save**.

After creating the Event Business Rule, creates the following Event Business Rule Configurations for the appropriate Event Types and Countries to count towards the 10 event restriction:

| Field | Speaker Programs in the US | Speaker Programs in Germany | Congresses in the US | Congresses in Germany |
| --- | --- | --- | --- | --- |
| event\_business\_rule\_\_v | Cross-Event Attendee Limits (Populated automatically) | Cross-Event Attendee Limits (Populated automatically) | Cross-Event Attendee Limits (Populated automatically) | Cross-Event Attendee Limits (Populated automatically) |
| event\_type\_\_v | speaker\_program\_\_v | speaker\_program\_\_v | congress\_\_v | congress\_\_v |
| country\_\_v | United States | Germany | United States | Germany |
| rule\_start\_date\_\_v | January 1, 2020 | January 1, 2020 | January 1, 2020 | January 1, 2020 |
| rule\_end\_date\_\_v | December 31, 2050 | December 31, 2050 | December 31, 2050 | December 31, 2050 |

An event organizer plans a Speaker Program and adds Clinton Ackerman as an attendee. However, Clinton Ackerman has already been invited to six Speaker Programs and five Congresses within the same rolling 180 day period, so when the event is submitted for approval, the following soft warning displays:

Clinton Ackerman has or will attend 11 events. Attendees cannot attend more than 10 events.

The organizer is prompted to leave a reason for inviting Clinton Ackerman to the event. After providing the reason, the organizer can proceed with planning the event.

[![Closed](../../../../Skins/Default/Stylesheets/Images/transparent.gif)Meal Opt-In Attendance Limit Rules](#)

#### Limiting Based on a Single Event Type

The admin wants to restrict inviting a Professional-type attendee to Lunch and Learns if they have already opted into four or more meals at Lunch and Learns within a rolling 60 day period.

To implement this restriction:

1. Navigate to the **Event Business Rules** tab.
2. Create an Event Business Rule with an object type of **Meal Opt-In Attendance Limit Rule**.
3. Populate the following fields:

   | Field | Value |
   | --- | --- |
   | name\_\_v | Meal Opt-in Limit |
   | run\_rule\_event\_action\_\_v | submit\_for\_approval\_\_v |
   | attendee\_account\_type\_\_v | professional\_\_v |
   | attendee\_status\_\_v | ;;approved\_\_v:invited\_\_v,accepted\_\_v;;closed\_\_v:attended\_\_v,signed\_\_v;; |
   | global\_rule\_\_v | Unselected |
   | warning\_type\_\_v | Hard Warning |
   | warning\_text\_\_v | EM\_RULE\_MEAL\_OPT\_IN\_ATTENDANCE;;EVENT\_BUSINESS\_RULE\_WARNING  (Populated automatically) |
   | date\_threshold\_type\_\_v | Rolling |
   | rolling\_period\_\_v | 60 |
4. Select **Save**.

The admin then creates the following Event Rule Configuration:

| Field | Event Rule Configuration |
| --- | --- |
| event\_business\_rule\_\_v | Meal Opt-In Limits |
| event\_type\_\_v | lunch\_and\_learn\_\_v |
| country\_\_v | United States |
| rule\_start\_date\_\_v | 01/01/2020 |
| rule\_end\_date\_\_v | 12/31/2050 |
| limit\_quantity\_\_v | 4 |

An event organizer schedules a Lunch and Learn and invites Clinton Ackerman. Clinton Ackerman has already been invited to three other Lunch and Learns within the 60 day rolling period where he has opted into receiving a meal. When the event is submitted for approval, the Meal Op-In Limits rule passes and the organizer can continue scheduling the event.

#### Limiting Based on Multiple Event Types

The admin wants to restrict adding a Professional-type attendee to the following event types based on the following conditions:

* Lunch and Learn – Attendees should be restricted from being invited if they have already opted into four or more meals at Lunch and Learns within the calendar month
* Congress – Attendees should be restricted from being invited if they have already opted into two or more meals at Congresses within the calendar month

To implement these restrictions:

1. Navigate to the **Event Business Rules** tab.
2. Create an Event Business Rule with an object type of **Meal Opt-In Attendance Limit Rule**.
3. Populate the following fields:

   | Field | Value |
   | --- | --- |
   | name\_\_v | Meal Opt-in Limit |
   | run\_rule\_event\_action\_\_v | submit\_for\_approval\_\_v |
   | attendee\_account\_type\_\_v | professional\_\_v |
   | attendee\_status\_\_v | ;;approved\_\_v:invited\_\_v,accepted\_\_v;;closed\_\_v:attended\_\_v,signed\_\_v;; |
   | global\_rule\_\_v | Unselected |
   | warning\_type\_\_v | Hard Warning |
   | warning\_text\_\_v | EM\_RULE\_MEAL\_OPT\_IN\_ATTENDANCE;;EVENT\_BUSINESS\_RULE\_WARNING  (Populated automatically) |
   | date\_threshold\_type\_\_v | Calendar Month |
4. Select **Save**.

After creating the business rule, create the following Event Rule Configurations:

| Field | Lunch and Learn Record | Congress Record |
| --- | --- | --- |
| event\_business\_rule\_\_v | Meal Opt-In Limits | Meal Opt-In Limits |
| event\_type\_\_v | lunch\_and\_learn\_\_v | congress\_\_v |
| country\_\_v | United States | United States |
| rule\_start\_date\_\_v | 01/01/2020 | 01/01/2020 |
| rule\_end\_date\_\_v | 12/31/2050 | 12/31/2050 |
| limit\_quantity\_\_v | 4 | 2 |

An event organizer schedules a Lunch and Learn and invites Clinton Ackerman. However, Clinton Ackerman has already been invited to four Lunch and Learns where he has already opted into receiving a meal. When the event is submitted for approval, the following hard warning displays:

Clinton Ackerman has opted-in for 4 meals at United States Lunch and Learn events. Attendees cannot attend additional events if they have opted-in for more than 4 meals.

Clinton Ackerman must be removed as an attendee before the event organizer can proceed with planning the event.

[![Closed](../../../../Skins/Default/Stylesheets/Images/transparent.gif)Cross-Event Meal Opt-In Attendance Limit Rule](#)

#### Limiting Based on Meals from a Combination of Event Types

The admin wants to restrict Professional-type attendees from being invited to an event if they have already opted into five or more meals within the calendar month.

To implement this restriction:

1. Navigate to the **Event Business Rules** tab.
2. Create an Event Business Rule with an object type of **Cross-Event Meal Opt-In Attendance Limit Rule**.
3. Populate the following fields:

   | Field | Value |
   | --- | --- |
   | Name | Total Meal Opt-in Limit |
   | run\_rule\_event\_action\_\_v | submit\_for\_approval\_\_v |
   | limit\_quantity\_\_v | 4 |
   | attendee\_account\_type\_\_v | professional\_\_v |
   | attendee\_status\_\_v | ;;approved\_\_v:invited\_\_v,accepted\_\_v;;closed\_\_v:attended\_\_v,signed\_\_v;; |
   | global\_rule\_\_v | Unselected |
   | warning\_type\_\_v | Hard Warning |
   | warning\_text\_\_v | EM\_RULE\_CROSSEVENT\_MEAL\_OPT\_IN\_ATTENDANCE;;EVENT\_BUSINESS\_RULE\_WARNING  (Populated automatically) |
   | date\_threshold\_type\_\_v | Calendar Month |
4. Select **Save**.

The admin then creates the following Event Business Rule Configurations to define what types of events count towards the four meal limit:

| Field | Lunch and Learn Record | Congress Record | Speaker Program Record |
| --- | --- | --- | --- |
| event\_business\_rule\_\_v | Total Meal Opt-in Limit | Total Meal Opt-in Limit | Total Meal Opt-in Limit |
| event\_type\_\_v | lunch\_and\_learn\_\_v | congress\_\_v | speaker\_program\_\_v |
| country\_\_v | United States | United States | United States |
| rule\_start\_date\_\_v | 01/01/2020 | 01/01/2020 | 01/01/2020 |
| rule\_end\_date\_\_v | 12/31/2050 | 12/31/2050 | 12/31/2050 |

An event organizer plans a Lunch and Learn and invites Clinton Ackerman. However, Clinton Ackerman has already opted into meals at one other Lunch and Learn, two Congresses, and two Speaker Programs. When the event is submitted for approval, the following hard warning displays:

Clinton Ackerman has opted-in for 5 meals at events. Attendees cannot attend additional events if they have opted-in for more than 4 meals.

[![Closed](../../../../Skins/Default/Stylesheets/Images/transparent.gif)Per Event Attendance Limit Rule](#)

#### Limiting Number of a Single Attendee Type and Event Type

The admin wants to restrict attendance to Lunch and Learns to between 5 and 10 Professional-type attendees that have accepted the invitation.

To implement this restriction:

1. Navigate to the **Event Business Rules** tab.
2. Create an Event Business Rule with an object type of **Per Event Attendance Limit Rule**.
3. Populate the following fields:

   | Field | Value |
   | --- | --- |
   | Name | Professional Attendee Limits |
   | run\_rule\_event\_action\_\_v | submit\_for\_approval\_\_v |
   | attendee\_account\_type\_\_v | professional\_\_v |
   | attendee\_status\_\_v | ;;accepted\_\_v;; |
   | global\_rule\_\_v | Unselected |
   | warning\_type\_\_v | Hard Warning |
   | warning\_text\_\_v | EM\_RULE\_PER\_EVENT\_ATTENDANCE;;EVENT\_BUSINESS\_RULE\_WARNING  (Populated automatically) |
4. Select **Save**.

The admin then creates an Event Business Rule Configuration record with the following properties:

| Field | Value |
| --- | --- |
| event\_business\_rule\_\_v | Professional Attendee Limits  (Populated Automatically) |
| event\_type\_\_v | lunch\_and\_learn\_\_v |
| country\_\_v | United States |
| rule\_start\_date\_\_v | 01/01/2020 |
| rule\_end\_date\_\_v | 12/31/2050 |
| minimum\_quantity\_\_v | 5 |
| maximum\_quantity\_\_v | 10 |

An event organizer plans a Speaker Program and attempts to invite 12 Professional-type attendees. When the event is submitted for approval, the following hard warning displays:

United States Speaker Program must have between 5 and 10 attendees.

Two attendees must be removed before the event can proceed with planning.

#### Limiting Number of Multiple Attendee Types

The admin wants to restrict the number of attendees that can be invited to a Speaker Program. The event should not have more than ten attendees, at least five of which must be Prescribers.

To implement this restriction:

1. Navigate to the **Event Business Rules** tab.
2. Create two Event Business Rules, both with the **Per Event Attendance Limit Rule** object type, with the following field values:

   | Field | Rule 1 Value | Rule 2 Value |
   | --- | --- | --- |
   | name\_\_v | Speaker Program Total Attendance Limit | Speaker Program Prescriber Attendance Limit |
   | run\_rule\_event\_action\_\_v | submit\_for\_approval\_\_v | submit\_for\_approval\_\_v |
   | attendee\_account\_type\_\_v | NULL | prescriber\_\_v |
   | attendee\_status\_\_v | ;;invited\_\_v;;accepted\_\_v;; | ;;invited\_\_v;;accepted\_\_v;; |
   | global\_rule\_\_v | Unselected | Unselected |
   | warning\_type\_\_v | Soft Warning | Hard Warning |
   | warning\_text\_\_v | EM\_RULE\_PER\_EVENT\_ATTENDANCE;;EVENT\_BUSINESS\_RULE\_WARNING  (Populated automatically) | EM\_RULE\_PER\_EVENT\_ATTENDANCE;;EVENT\_BUSINESS\_RULE\_WARNING  (Populated automatically) |
   | comment\_required\_\_v | Optional | n/a |

The admin then creates an Event Business Rule Configuration record with the following properties:

| Field | Configuration Record for Rule 1 | Configuration Record for Rule 2 |
| --- | --- | --- |
| event\_business\_rule\_\_v | Speaker Program Total Attendance Limit  (Populated Automatically) | Speaker Program Prescriber Attendance Limit  (Populated Automatically) |
| event\_type\_\_v | lunch\_and\_learn\_\_v | lunch\_and\_learn\_\_v |
| country\_\_v | United States | United States |
| rule\_start\_date\_\_v | 01/01/2020 | 01/01/2020 |
| rule\_end\_date\_\_v | 12/31/2050 | 12/31/2050 |
| minimum\_quantity\_\_v | 0 | 5 |
| maximum\_quantity\_\_v | 10 | Null |

An event organizer plans a Speaker Program and attempts to invite 12 attendees, four of which are Prescribers. When the event is submitted for approval, the following hard warning displays:

United States Speaker Program must have at least 5 Prescriber attendees.

The event organizer invites an additional Prescriber, then resubmits the event for approval. Next, a soft warning displays, warning the organizer that the event exceeds the number of attendees that can be added to her event:

United States Speaker Program cannot exceed 10 attendees total.

The organizer determines that the additional two attendees are required for the event and decides to keep them. Even though a comment is not required, the event organizer adds one to explain exceeding the attendance limit for this event. After submitting the comments, the organizer can proceed with planning the event.

### Related Topics

[Event Business Rules Overview](EventBusinessRules.htm)

[Creating Event Attendance Rules](AttdRules.htm)

[Warning Text and Tokens](WarningTextTokens.htm)
