Business Context
Highmark Health's Business Analytics team needs a provider-specialty view of paid medical claims for active members.
Task
Write a PostgreSQL query that joins members, claims, and providers and returns the number of qualifying claims for each provider specialty.
Requirements
- Include only claims with
claim_status = 'PAID' and a service_date in calendar year 2025.
- Include claims only when the related member has
member_status = 'ACTIVE'.
- Group results by provider specialty, labeling a missing specialty as
Unknown.
- Return
provider_specialty and claim_count, ordered alphabetically by specialty.