It involves creating a checkbox on the Point Log itself that basically had the logic I wish I could put in the automation, but it’s a fine workaround for now.
You need to be cautious when combining database formula fields and automations to achieve a specific goal because they are two independent services, and the relative timing of changes cannot be guaranteed.
For example, the linked Assignees change to trigger the automation. The filter in the automation’s delete action checks the value of the formula field.
In parallel, the Assignee change causes the formula field to be updated, but it is not guaranteed that this update will have completed before the filter check occurs. If the formula service is busy updating other entities, it is possible that the automation will not perform as intended.
Possibly. But let me check some things first.
You wrote…
Is this correctly understood as: if an Assignee is unlinked from a Task, then delete all of the Point Logs belonging to the Task that also belong to the user who is the unlinked Assignee
?
In case it’s not clear what is going on, here’s the explanation:
the formula takes all the assignees for the Task and selects only the one which matches the User for the Point Log. It will return true if there isn’t a match - this will be true if the list of assignees no longer contains the User for this Point Log. In such an event the automation will cause the Point Log to delete itself.
Strictly speaking, it is not an exact match for what you asked for, since you wanted a trigger when the unlinking occurs, but the solution above will cause the Point Log to be deleted if there is any time in its lifecycle when the User is not amongst the list of Assignees (e.g. if a Point Log is created for a Task and the User is not an Assignee at that time) but I hope this distinction is not important.