Zupa Insurance Database Model Sheet DM01

 

Zupa Insurance Database Model

In the dynamic landscape of the insurance industry, efficient data management is paramount. A well-structured database not only streamlines operations but also empowers data-driven decision-making. This document outlines a comprehensive database model for Zupa Insurance, focusing on key entities, relationships, and considerations for optimal performance and scalability. We'll explore how to we get data modeling requests to create a robust foundation for Zupa's data assets.
This is how we might get information/Handover from Business Analysts and Data Modelers

I. Zift Tables

These tables form the foundation of the Zupa Insurance system.

1. Customers

Description: Stores information about individuals or entities who purchase insurance policies. This table is crucial for customer relationship management (CRM).

ColumnTypeNotes
customer_idINTPRIMARY KEY, AUTO_INCREMENT
first_nameVARCHAR(255)NOT NULL
last_nameVARCHAR(255)NOT NULL
date_of_birthDATE-
genderVARCHAR(10)-
addressVARCHAR(255)-
cityVARCHAR(100)-
stateVARCHAR(50)-
zip_codeVARCHAR(10)-
emailVARCHAR(255)UNIQUE, for data integrity
phone_numberVARCHAR(20)-
customer_typeVARCHAR(50)e.g., "Individual," "Business"
created_atTIMESTAMPDEFAULT CURRENT_TIMESTAMP
updated_atTIMESTAMPON UPDATE CURRENT_TIMESTAMP

Primary Key: `customer_id`

2. Policies

Description: Stores information about insurance policies. This is a core table for managing insurance products and policy details.

ColumnTypeNotes
policy_idINTPRIMARY KEY, AUTO_INCREMENT
customer_idINTFOREIGN KEY REFERENCES Customers(customer_id), NOT NULL
policy_typeVARCHAR(100)e.g., "Auto," "Home," "Life."
policy_numberVARCHAR(255)UNIQUE, NOT NULL
issue_dateDATENOT NULL
effective_dateDATENOT NULL
expiration_dateDATENOT NULL
premium_amountDECIMAL(10, 2)NOT NULL
payment_frequencyVARCHAR(50)e.g., "Monthly," "Annually"
policy_statusVARCHAR(50)e.g., "Active," "Inactive," "Cancelled."
deductible_amountDECIMAL(10, 2)-
coverage_amountDECIMAL(10, 2)-
created_atTIMESTAMPDEFAULT CURRENT_TIMESTAMP
updated_atTIMESTAMPON UPDATE CURRENT_TIMESTAMP

Primary Key: `policy_id`

Foreign Key: `customer_id` (references `Customers`)

3. Claims

Description: Stores information about insurance claims. Efficient claims processing is vital in the insurance sector.

ColumnTypeNotes
claim_idINTPRIMARY KEY, AUTO_INCREMENT
policy_idINTFOREIGN KEY REFERENCES Policies(policy_id), NOT NULL
customer_idINTFOREIGN KEY REFERENCES Customers(customer_id), NOT NULL
claim_numberVARCHAR(255)UNIQUE, NOT NULL
claim_dateDATENOT NULL
claim_statusVARCHAR(50)e.g., "Open," "Pending," "Approved," "Denied."
claim_amountDECIMAL(10, 2)NOT NULL
claim_descriptionTEXT-
incident_dateDATE-
incident_locationVARCHAR(255)-
created_atTIMESTAMPDEFAULT CURRENT_TIMESTAMP
updated_atTIMESTAMPON UPDATE CURRENT_TIMESTAMP

Primary Key: `claim_id`

Foreign Keys: `policy_id` (references `Policies`), `customer_id` (references `Customers`)

7. Policy_Beneficiaries

Description: Links policies to their beneficiaries, allowing for multiple beneficiaries per policy.

ColumnTypeNotes
policy_idINTFOREIGN KEY REFERENCES Policies(policy_id), NOT NULL
customer_idINTFOREIGN KEY REFERENCES Customers(customer_id), NOT NULL
beneficiary_percentageDECIMAL(5, 2)-

Primary Key: (`policy_id`, `customer_id`) (Composite primary key)

Foreign Keys: `policy_id` (references `Policies`), `customer_id` (references `Customers`)

III. Application-Specific Tables

Here are the tables for the other applications:

9. RCM_Data

Description: Stores detailed policy information, claims data, and related financial data from the RCM PostgreSQL database. This is important for financial data analysis in the insurance domain.

ColumnTypeNotes
rcm_data_idINTPRIMARY KEY, AUTO_INCREMENT
policy_idINTFOREIGN KEY REFERENCES Policies(policy_id), NOT NULL
claim_idINTFOREIGN KEY REFERENCES Claims(claim_id)
financial_data_idINTFOREIGN KEY REFERENCES Financial_Data(financial_data_id), NOT NULL
detailed_policy_infoTEXTDetailed information about the policy.
detailed_claim_infoTEXTDetailed information about the claim.
financial_dataDECIMAL(10,2)Financial data related to claim or policy.
created_atTIMESTAMPWhen the record was created.
updated_atTIMESTAMPWhen the record was last updated.

Primary Key: `rcm_data_id`

Foreign Keys: `policy_id` (references `Policies`), `claim_id` (references `Claims`), `financial_data_id` (references `Financial_Data`)

10. Financial_Data

Description: Stores financial data. This table is designed to remove the multi-valued dependency of `financial_data_id`

ColumnTypeNotes
financial_data_idINTPRIMARY KEY, AUTO_INCREMENT
financial_valueDECIMAL(10,2)Financial data related to claim or policy.
created_atTIMESTAMPWhen the record was created.

Primary Key: `financial_data_id`

11. Microsoft_CRM_Data

Description: Stores online transaction data, customer interactions, and marketing campaign data from Microsoft CRM Dynamics. Essential for marketing analytics and customer journey tracking.

ColumnTypeNotes
crm_data_idINTPRIMARY KEY, AUTO_INCREMENT
customer_idINTFOREIGN KEY REFERENCES Customers(customer_id), NOT NULL
transaction_idINTIdentifier for online transaction.
transaction_dateTIMESTAMPDate and time of the online transaction.
interaction_typeVARCHAR(100)Type of customer interaction (e.g., "Website Visit," "Email Click").
interaction_dateTIMESTAMPDate and time of interaction.
marketing_campaign_idINTIdentifier for marketing campaign.
campaign_responseVARCHAR(100)Customer response to marketing campaign.
created_atTIMESTAMPWhen the record was created.
updated_atTIMESTAMPWhen the record was last updated.

Primary Key: `crm_data_id`

Foreign Key: `customer_id` (references `Customers`)

  • 12. Sensitive_User_Data

    Description: Stores sensitive user information from CSV files. These CSV files are provided in a password-protected ZIP format. The solution must address data security and compliance requirements for handling this data. This table is critical for managing PII data.

    Action item: To check if we can use better way of storing PII data.

    13. SCD_Integration

    Description: This is not a table, but a placeholder for the integration with the existing Slowly Changing Dimension (SCD) system. The MOI will provide data to this system for master data management.

    • The specific tables and data exchange format will need to be defined in collaboration with the team managing the SCD system.
    • Key requirements include:
      • Identifying the common key(s) for identity resolution (e.g., `customer_id`, email, phone number).
      • Defining the data feed mechanism (e.g., API, batch file transfer).
      • Ensuring data quality and consistency between the Zupa system and the SCD system.
      • Handling data updates and changes according to the SCD system's requirements.
      • Consider using a separate staging area for data exchange with the SCD system.
    • A separate document or specification should detail the SCD integration.

    Please comment about the clarifying questions we should ask BA.

Comments

Popular posts from this blog

Diving Deeper into the Data Engineer Toolkit -101

Data Warehousing: From Basics to Best Practices - Hold My Data!

Your Entry to the Data Engineer World