EventWhoRelation

Represents the relationship between an event and a lead or contacts. This derived object is a filtered version of the EventRelation object; that is, IsParent is true and IsWhat is false. It doesn’t represent relationships to invitees or to accounts, opportunities, or other objects.

EventWhoRelation allows a variable number of relationships: one lead or up to 50 contacts. Available only if you’ve enabled Shared Activities for your organization.

Introduced in API version 29.0.

describeSObjects(), query(), retrieve()

  • Type: reference

  • Properties: Filter, Group, Nillable, Sort

  • Relationship name: Account

  • Relationship type: relationship

  • Refers to: Account

  • Type: reference
  • Properties: Filter, Group, Nillable, Sort
  • Description: Indicates the ID of the event.
  • Relationship name: Event
  • Relationship type: relationship
  • Refers to: Event
  • Type: reference
  • Properties: Filter, Group, Nillable, Sort
  • Description: Indicates the ID of the contacts or lead related to the event.
  • Relationship name: Relation
  • Relationship type: polymorphic
  • Refers to: Contact, Lead
  • Type: string
  • Properties: Filter, Group, Nillable, Sort
  • Description: Indicates whether the person related to the event is a contact or lead.
  • Apex example that queries relations to a contact or lead: ```

List whoRelations = [SELECT Id, Relation.Name FROM EventWhoRelation WHERE EventId = ‘00UD0000005zijD’];