function readOnly(count){ }
Starting November 20, the site will be set to read-only. On December 4, 2023,
forum discussions will move to the Trailblazer Community.
+ Start a Discussion
Ione JuniorIone Junior 

INVALID_CROSS_REFERENCE_KEY error when DELETING Attachments

Hello I deleted the parent of an Attachment, now I can't change the parentId from the attachment and can't delete the attachment even using Apex Data Loader
The error id: INVALID_CROSS_REFERENCE_KEY
I can't even open the attachment on "Overall Top Files by Storage Utilization"
I tried to delete this via an Apex class, and it's normally selected but on delete, it returns the same error.
In Data Loader I can export normally.
Mikola SenykMikola Senyk
Maybe parent object of attachment still in Recycle Bin? Try to find and remove it.
Ione JuniorIone Junior
This isn't in Recycle Bin