1

I tried several ways:

  1. delete it from the UI After I click "Empty you recycle bin" button, nothing in the recycle bin.

  2. use database.emptyRecycleBin() Even though there is nothing in the recycle bin, I am able to query it back using "all rows".

  3. use workbench

It first gives me a warning "It does not seem like this record can be deleted. Are you sure you wish to continue?"

Then I hit confirm delete it gives me Result: "Entity Is Deleted" Status: "ENTITY_IS_DELETED"

3
  • Did you try calling undelete on record?
    – Ashwani
    Sep 8 '15 at 18:16
  • @Ashwani, I just tried from the work bench: Result: Entity Is Not In The Recycle Bin
    – sfdcnoob
    Sep 8 '15 at 18:24
  • @sfdcnoob Your record is in "Stage 2" deletion. It'll disappear after the next batch purging.
    – sfdcfox
    Sep 8 '15 at 18:28
5

The system doesn't immediately purge deleted records once you empty the Recycle Bin. Instead, they're flagged for purging, which runs periodically in the background. Your record will be gone after the next sweep. I do not remember the exact time frame for this process, but it's definitely within 24 hours going to happen at some point. See this knowledge article for details:

Record data has 3 stages of deletion:

Stage 1 - Deleted to Recycle Bin - Data in this stage can still be recovered from the recycle bin. This can also be referred to as soft deleted.

Stage 2 - Emptied from the Recycle Bin or hard deleted - Data in this stage cannot be recovered from the recycle bin but can be accessed and exported from the API using Export All (queryall) in DataLoader v21 and higher or other api tools. Records can also be put in this state directly by using the hard delete option in the Data Loader.

Stage 3 - Physically/Permanently deleted - Data in this stage has been wiped from database and only recoverable by contacting Salesforce to request a Data Recovery Service (fee associated). Please click here to learn more about the Data Recovery Process.

3
  • 1
    Hi sfdcfox, I actually emptied the recycle bin 1 week ago. But today when I queried all rows I still got the record.
    – sfdcnoob
    Sep 8 '15 at 18:43
  • @sfdcnoob Curious. I'll see if I can find some documentation on it. It appears they've significantly increased the time deleted records can be queried with queryMore.
    – sfdcfox
    Sep 8 '15 at 18:50
  • I was talkng to the good folks at Salesforce support. They said to run a purge use workbench. You can find it here: workbench.developerforce.com/purge.php In my case it was stopping me activating matching rules Aug 29 '17 at 1:15

Your Answer

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

Not the answer you're looking for? Browse other questions tagged or ask your own question.