Realtionship Management in Sage CRM v6.2

By | January 19, 2009

Want to propagate communications of the parent entity to that of all the child entities for parent/child relationship in Sage CRM version6.2? Check this one.

Sage CRM version 6.2 has provided a very strong and effective feature as “Related Entities” functionality. Using this particular functionality we can create parent/child and parent/sibling relationships between the entities on the fly. This functionality has enabled us to create various “one to many” and “many to one” relationships and also some reciprocal relationships between the entities.

Using “Related Entities” feature, it is very easy to establish the parent/child relationship between two entities. We can establish the “one to many” relation between one entity (parent) with another entity (child) using parent/child relationship. Let’s consider one opportunity can have multiple companies as the children and now we want to propagate all the communications for an opportunity to that of all the child company entities. Here are the steps that we have analyzed for the same with some “Out Of Box” thinking.

1. To define a new relation type Go to Administration à Data Management à Manage Relation Types à New.
2. Select relation type “parent/child”, “opportunity” as a “parent entity” and “Company” as a “Secondary entity”, enter the relationship names and click on Save button to save the relation.
3. At the backend the entry is made for this particular relation type in “RelatedEntityLinks” table with renl_entity1 as “opportunity” and renl_entity2 as “Company”.
4. Now for an opportunity we can go to the “Relationships“ tab and add several child company entities. All these entries are made in “RelatedEntityData” table.
5. In “RelatedEntityData” table we can find id for the relationship type that we have created above as rend_relatedentitylinkid and we can also find the id’s for parent and child entities as rend_entity1id and rend_entity2id.
6. This way we can find id’s for all the company entities that are chidren for the particular opportunity.
7. Now as we know when if we create a communication for an opportunity an entry is also made in Comm_Link table where we can find to which all entities that communication is linked.
8. What we can do is we can write a table level scripts which will make use of the child entity id’s that we have found from the “RelatedEntityData” table as mentioned in point number 5 and make entry in the Comm_Link table to update cmli_comm_companyid values for the particular communicationid.

This way all the communications of parent entity i.e. opportunity can be attached to all the child companies associated with that particular opportunity.