Archival of SMS History Records

Background information

SMS-Magic does not have its archive mechanism for SMS History data. If you are facing storage usage problems for your Salesforce org and want to clear some storage by deleting older SMS History data then you can do it using Data Loader or Workbench tools.

Before you delete data, we recommend you to take back-up of SMS data.

Back up Procedure of SMS History Records

This can be done using Workbench & Dataloader. Be sure to include this in the KB.

Steps I – Take Data Back up (Full Export for SMS History Object)

Step II – Prepare file for Deletion

Step III – run deletion

Step IV – Review Success & Failure logs from Dataloader / Workbench.

Best Practices to delete SMS History Records

  1. Don’t Delete SMS History in a single go
  2. Try Deleting SMS History in chunks by using filters
  3. Verify after every chunk gets deleted
  4. It is advisable to delete the SMS History by date
  5. Check if any Process Builders/Workflows/ Apps are active on SMS History object. If yes, deactivate them.

Methods to delete SMS history records

  1. By Dataloader/Workbench.
  2. By Query from Developer Console(if req we can provide the queries)
  3. By List Views

Steps to Delete SMS History through Workbench

Incorrect records are deleted or the customer wants to restore the deleted messages. They should be able to do it using a backup file.

This can be done using Workbench & Dataloader. Be sure to include this in the KB.

Step I – Take Data Back up (Full Export for SMS History Object)
  1. Login to https://workbench.developerforce.com/
  2. Enter the org through which you are logging in (I have selected production)
  3. Enter the API version. (I have selected the latest version.)
  • In Action to perform – add “SOQL Query” and select the object as smagicinteract_smsMagic__c (This is the API name of SMS History object)
  • Now you need to run the query by selecting the column you wish to display. You can either select listview or select Bulk CSV.

Listview data –

After Selecting Bulk Csv, it redirects to a page where the CSV file is created and displays the status when it is completed.

To view the created file you need to login to salesforce and search “Bulk Data load jobs” in the quick find box.

To view the CSV file, click on “View Request”.

Step II – Prepare file for Deletion

Select Data→ Delete → Choose the file → Next → Select the CSV (The one requested from the salesforce to view the request).

Step III – run deletion (If you select -Permanently hard delete records option, you won’t be able to see/track deleted records from Recycle bin)
Step IV – Review Success & Failure logs from Workbench

Was This Article Helpful?

Important Announcement!

URGENT! Please register the 10-digit business phone number (e.g. 555-555-5555) that your organization uses to send texts to consumers in the U.S. Failure to register may cause heavy penalties and disruption to all your text messaging communications.