locked
delete related records when deleting the contact RRS feed

  • Question

  • hi forum!

    i have a custom entity between contacts and another custom entity (contacts, cust. entity (help entity), cust. entity). in the third entity is a relation to the contact. if i delete the whole contact the record stays with all the data except the contact lookup entry... is it possible to delete also this relation when deletin the contact? in that it's not necessary to delete all the "empty" records...

    thanks for your hints!

    Thursday, March 3, 2011 1:15 PM

Answers

  • Have you checked out "Relationship Behavior"(should be at the bottom) when opening the relationship between the 2 entities, this is where you can configure what to do incase a parent entity is deleted etc.
    Halldór Jóhannsson
    • Marked as answer by CRMBE Friday, March 4, 2011 3:00 PM
    Thursday, March 3, 2011 1:59 PM
  • Thanks Halldor! I could solve it with delete: cascade all!
    • Marked as answer by CRMBE Friday, March 4, 2011 3:00 PM
    Friday, March 4, 2011 3:00 PM

All replies

  • You would have to use a plugin since there is no built-in functionality that would allow you to iterate through all the related records.
    Thursday, March 3, 2011 1:59 PM
  • Have you checked out "Relationship Behavior"(should be at the bottom) when opening the relationship between the 2 entities, this is where you can configure what to do incase a parent entity is deleted etc.
    Halldór Jóhannsson
    • Marked as answer by CRMBE Friday, March 4, 2011 3:00 PM
    Thursday, March 3, 2011 1:59 PM
  • I'll check and test that out!

    Thursday, March 3, 2011 3:17 PM
  • Thanks Halldor! I could solve it with delete: cascade all!
    • Marked as answer by CRMBE Friday, March 4, 2011 3:00 PM
    Friday, March 4, 2011 3:00 PM