Your question is Running Total and Customer Ranking. Start with the requirements and the two tables on the right.
Run and submit as often as you like. When you're ready, talk me through your approach or go straight to the code.
Mutual of Omaha's claims analytics team needs a regional view of paid claim activity. Write a PostgreSQL query that aggregates paid claims per policyholder, calculates a regional running total, and ranks policyholders within each region.
claim_status = 'Paid' and policyholders with at least one non-null claim amount.policyholder_id ascending as a tie-breaker.| Column | Type | Description |
|---|---|---|
| policyholder_idPK | INT | Unique policyholder identifier |
| policyholder_name | VARCHAR(100) | Policyholder name |
| region | VARCHAR(30) | Geographic servicing region |
| Column | Type | Description |
|---|---|---|
| claim_idPK | INT | Unique claim identifier |
| policyholder_id | INT | Referenced policyholder identifier |
| claim_date | DATE | Date the claim was recorded |
| claim_amount | DECIMAL(12,2) | Claim amount |
| claim_status | VARCHAR(20) | Claim processing status |