Recovering deleted records

Hi,

I'd like to ask a general question regarding best practices. In cases like when a client mistakenly deletes a record from any Sugar module, such as Accounts, what is the best way to go on about recovering it? Simply changing the record's deleted flag back to false using SQL seems like the most straightforward way, but what about the record's relationships? Do I have to set their flags back to false one by one? Or is recovering a deleted record not recommended at all?

Any insight on the matter would be appreciated.

Regards,

Samuel.

Parents Reply
  • For a simple deletion this could work. But mostly such deletions were created by more complex operations like  e.g. merging of records. In the merging case, the relationships are deleted between the existing parts and newly created with the new parts. That makes it nearly impossible to restore the old relationships.

    In an example I merged two contacts from one account to another account. The result in the accounts_contacts table looks like this and shows the problem to identify the changes:

    Harald Kuske
    Principal Solution Architect – Professional Services, EMEA
    hkuske@sugarcrm.com
    SugarCRM Deutschland GmbH

Children