Roles and relationships

Customer can be either persons or companies. They are connected through roles that shows relationships between them. The system has to be configured with the types of roles needed.

For example, let's say we have employee -> company as a role. That will allow us to link persons to companies as employees. We could of course also have member of board -> company as a separate role. Let's also assume we have a role branch office -> head office that links two companies.

Note that with roles you can connect both ways, it's possible for a company to have several employees as expected, but it's also possible for a person to be connected to several companies. For example you can have a person that's a member of the board on 10 different companies and employed at yet another one.

Now we can enter the head office (Astronaut Service) as a new company with some employees. Once that is done, we click on connect entity and pick to add a new branch office (Astronaut Service London) from the list there. Once the details are entered the main screen will update with the branch office and there will be a link back to the head office.

We now have a structure that looks like this:

Astronaut Service
    Employee Jan Jansson
    Employee Lars Larsson
    Branch office Astronaut Service London
        Employee Nils Nilsson
        Employee Sven Svensson

There is a special kind of role usually named "Duplicate". Say we notice a duplicate record of Astronaut Service with another employee called Hans Hansson. We fix this in two steps, the first is to tell the system that there is a duplicate. This is done by connecting the duplicate company to the main company. We find the main company and click on the connect entity link, choose duplicate account on the role drop down and search for Astronaut.

This will give a list of both the other Astronaut service companies, one will already be connected to the main account though the branch office role so we click on the connect link for the other to create the role between them.

The new structure looks like this:

Astronaut Service
    Employee Jan Jansson
    Employee Lars Larsson
    Branch office Astronaut Service London
        Employee Nils Nilsson
        Employee Sven Svensson
    Duplicate account Astronaut Service
        Employee Hans Hansson

This new structure will stay in place until the actual merge is done. The link is used to tell the merge routine what to join, so it's important to have the main account roles setup correctly. The main account will be the one that remains after the merge, all the information on the duplicate accounts will be moved over to the main account and once it's just the name that remains the duplicate record will be deleted. This is a harmless operation as long as it's a true duplicate. Merging two different companies into one is possible, but it's very difficult to separate them out again. Other than that the operation is harmless.

After the merge is completed the structure will look like this:

Astronaut Service
    Employee Jan Jansson
    Employee Lars Larsson
    Employee Hans Hansson
    Branch office Astronaut Service London
        Employee Nils Nilsson
        Employee Sven Svensson

If you want a description of how the actual merge is done, read the Administration chapter of this manual.