Restore a deleted field

Hi there, I have mistakenly deleted one of our custom fields and was hoping there is a way to restore it along with the data?



Have a look in the database with phpMyAdmin - if it’s not there, you won’t be able to restore it, I am afraid. Unless you have backups (I am sure you do!)

For example if it’s a custom field on Contacts module, there should be a table contacts_cstm with your field there, with the suffix “_c”. So for example a field called “Age” will be “contacts_cstm.age_c” in the database.

This information will also help you restore the field from backup.

  • Get somebody who knows a bit of SQL,

  • re-create the field in Studio, run a QR&R

  • backup your current database to make sure you don’t mess up things further

  • load the database table contacts_cstm from backup, into a different auxiliary table

  • transfer the data from this table into the main database

Deleted from the View or Deleted from studio Fields?

Deleted from studio fields unfortunately…

Deleting a Field from Studio ->Module->Fields -> Field Name (Delete Action) will remove it from the Database, and when performing the DELETE Action, SuiteCRM does alert the user that ALL DATA associated with that field would be deleted if you carry on with the Action. Unfortunately that column has been removed from Database. Your only hope is to check with your Hosting Providers if they have any recent backups of your Database. If they do, you can copy just that one Deleted Column of cstm table and restore into your CRM DB.

Hi, I do have a backup file, however am not comfortable with SQL. Would you be able to explain to me in detail how to do this? That would be much appreciated!

Hi there,

Thank you so much. I do have a backup file but no support and limited knowledge SQL. If you could provide me with any additional information on how to import this field only that would be great.



I can share general overview of the process, you can google futher details yourself.
Via cPanel, you can go to PhpMyadmin and create a New Database. Import your backup DB data to it and then reach to the table which contains your deleted column, If your module was accounts then the table you need to check would be accounts_cstm. It will have custom fields. You can export that data of that table and then import it into your live DB.