Loading

Salesforce Error: Lookups on activities must have a unique domain. You cannot have multiple relationships to the same object.

Date de publication: Apr 29, 2024
Description

When a user creates a lookup relationship field on the Salesforce Activity Object and gets the following error message:

 

Validation Errors While Saving Record(s)
 

There were custom validation error(s) encountered while saving the affected record(s). The first validation error encountered was "Lookups on activities must have a unique domain. You cannot have multiple relationships to the same object.".
 

Click here to return to the previous page.

 

Résolution


This issue happens when there’s already an existing lookup relationship field on an object and then the user creates a second lookup relationship on that same object.

 

You can only have one lookup per object on the Activity object. Because of the complexity of the Activity object, you're only allowed one lookup to a specific type of object (for example, User) for custom Activity lookup fields. 

 

This is a system limitation.


Workaround:

You can delete the existing field on the Activity object. While in Lightning Experience, do the following steps: 

 

  1. Go to Setup > Object Manager > Activity > Fields & Relationships
  2. Click the drop-down arrow on the specific custom field
  3. Click Delete.

Note: Make sure to hard delete the custom field by switching to Salesforce Classic after performing the steps above. Failure to do so will still result in a validation error.

 

  1. Switch to Salesforce Classic
  2. Go to Setup > Customize > Activities > Activity Custom Fields > Deleted Fields
  3. Click Erase next to the field you wish to be permanently deleted.
 
Numéro d’article de la base de connaissances

000389963

 
Chargement
Salesforce Help | Article