Join us Sept 17 at .local NYC! Use code WEB50 to save 50% on tickets. Learn more >
MongoDB Event
Docs Menu
Docs Home
/
Relational Migrator
/ /

Refactor the Claim Domain

In this step, you will refactor the Claim domain by adding mappings for each related table in the relational database and embedding all claim-related information under a single MongoDB claim document. Since the Claim and Litigation domains are closely related, you will also recreate the many-to-many relationship between the two domains by referencing the Litigation entity from the claim document.

The Claim domain includes the following key entities:

  • Claim: Claim for coverage or compensation

  • Claim Party Role: An associative entity which links the following entities:

    • Party

    • Party Roles

    • Insurable Objects

  • Insurable Object Party Role: An associative entity which links the following entities:

    • Party

    • Party Roles

    • Insurable Objects

Refactoring the Claim & Litigation domain is the fourth step of the insurance data model example tutorial. Before you refactor the Claim & Litigation domain, ensure that you:

1

On the right side of the screen, the Mappings menu opens.

2

Next to Mappings from relational tables, click Add. Click Embedded array and select claim_party_role from the Source table drop-down menu.

Under the All fields checkbox, uncheck the claimIdentifier field and click Save and close.

3

Next to Mappings from relational tables, click Add and select Embedded documents. Choose insurable_object from the Source table drop-down menu.

Click Save and close.

4

Policy coverage details help establish the link between claims and policies. To embed the information from the policy_coverage_detail table, click Add and select Embedded array. Choose policy_coverage_detail from the Source table drop-down menu.

Under the All fields checkbox, uncheck the insurableObjectIdentifier field, and click Save and close.

5

Since Litigation is a separate entity, you just need to reference that entity from the claims document as an array of litigation identifiers.

Next to Mappings from relational tables, click Add and select Embedded array. Choose litigation_party_role from the Source table drop-down menu.

Under the All fields checkbox, uncheck the litigationIdentifier field, and click Save and close.

6

Now that you mapped all the necessary tables to the claim collection, you can delete the claimPartyRole collections from the MongoDB view of Relational Migrator.

After you map the Claim domain, refactor the Litigation domain in a similar manner. See Refactor the Litigation Domain.

Back

Refactor the Policy Domain

On this page