This question has been asked a few times before, but I've been unable to find a question that had an answer that actually led to the goal of finding a Parent Event from a child event.

Here are the questions I've read so far:

Find Parent Event of Child Event

How to identify parent of child events?

Problem Statement:

We recently implemented the new Lightning Sync for Outlook (found under Email > Outlook Integration and Sync" in Setup) for all of our SFDC Lightning Users. As a result, now anytime someone books an event with multiple attendees in Outlook, the end result in Salesforce is one primary (parent) Event and 1 or more child (IsChild = true) Events.

An exact scenario that occurred today which we're struggling with was that our Training Manager booked a GoToMeeting event for a customer, but she was not doing the training herself, just booking it. Instead, she added the Trainer and the Customer as invitees in the Outlook event. Salesforce synced this in with the Lightning Sync, but the PRIMARY/Parent Event is owned by the Event Organizer which is the Training Manager.

Problem is, the Trainer is the one actually participating in the Event, and after the Event is over the Trainer needs to update the status to Complete, but since the Trainers Event is a Child Event, and Child Events can't be edited, when they try to update it they get an error that "Only event organizers can update this field".

I advised them that, based on our security model, the Trainer could still complete the event, but only by going to the PARENT event and updating the information there directly, which in turn would update all child events accordingly.

Additional Observations:

  • The "IsChild" boolean is invisible to the UI, but can be made visible by creating a Formula (Boolean) field that pulls the value. This at least helps our end-users identify if they are viewing a Child record or the Parent.

  • All Child Events get their own Unique Event ID, and are visible when querying for Events with SOQL.

  • There doesn't appear to be any lookup relationship between a Child Event and the Parent Event, or any external ID field that holds the Parent ID.

  • The EventRelation object holds records for the Contact(s) associated with the Event, and there is a 1-to-1 count between Child Event records and EventRelation records for a single Primary Event, but the EventRelation record doesn't seem to store any relationship to the Child Event Id, only the Parent Event Id is available via the EventId column on EventRelation.

End Goal

Ultimately what I am investigating now and would like to achieve is a way to either display a Lookup Relationship to the primary Event on any related Child Event so they can easily navigate to the primary/parent Event, or override the Event View action with a custom page / controller that automatically redirects the user from a Child Event to its respective Parent Event, so that my end-users aren't confused and don't try fruitlessly to edit Events that they can't edit.

Both of these goals are proving much more difficult to accomplish than I'd expected, considering the odd data model. Am I missing something here, or is this a pain point that we all deal with?

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Browse other questions tagged or ask your own question.