<turbo-stream action="update" target="wiki_card"><template>

<h1>DELETE_FAILED</h1>
<div class="trix-content"><p>When transferring data to Salesforce, you might encounter this error message: E2120 - ECE_SForceDataError: We got an error back from SalesForce when trying to update or insert data in SalesForce: Error returned from SFDC on delete: [<strong>message: Your attempt to delete John Doe could not be completed because it is associated with the following contracts: Demo Inc.</strong> , statusCode: <strong>DELETE_FAILED</strong> ] , Data sent: Failed to get more info on data sent to SFDC.<br><br>This error occurs when you try to delete a record that has dependencies or related records that prevent its deletion. The message may vary slightly depending on the object and its relationships, but in general, Salesforce enforces referential integrity by blocking the deletion of records that are referenced elsewhere.</p><p><strong><u>Variations:&nbsp;</u></strong></p><ol><li><strong>"DELETE_FAILED: This record cannot be deleted because it is associated with existing records."</strong></li><li><strong>"DELETE_FAILED: The record you are trying to delete is referenced by another record and cannot be removed."</strong></li><li><strong>"DELETE_FAILED: Cannot delete this record as it is related to active transactions or associated objects."</strong></li></ol><p><strong><u>Solution:</u></strong></p><ul><li>If related records cannot be deleted, you may <strong>reassign them to another parent record. Edit related records and update the lookup field to point to another record.&nbsp;</strong>If many records are affected, use <strong>Data Loader</strong> or <strong>Workbench</strong> to mass update the related records.</li></ul><p><br></p></div>
</template></turbo-stream>

