Guidewire ClaimCenter analysts want to monitor how claim processing times change over time. Write a PostgreSQL query that calculates a three-claim rolling average for completed claims, grouped by claim type.
status = 'Closed'.processing_days as the number of calendar days between opened_date and closed_date.claim_type, ordered by closed_date and claim_id.| Column | Type | Description |
|---|---|---|
| claim_idPK | INT | Primary key for the claim |
| claim_number | VARCHAR(20) | ClaimCenter claim identifier |
| policyholder_id | INT | References policyholders.policyholder_id |
| claim_type | VARCHAR(30) | Claim classification |
| status | VARCHAR(20) | Current claim status |
| opened_date | DATE | Date the claim was opened |
| closed_date | DATE | Date the claim was closed |
| Column | Type | Description |
|---|---|---|
| policyholder_idPK | INT | Primary key for the policyholder |
| policyholder_name | VARCHAR(100) | Policyholder full name |
| region | VARCHAR(30) | Policyholder region |