Reference

Capstone Bronze: Grain and Star Modeling

Objective:
Design and validate a monthly insurance performance mart at product-line grain.

Deliverables:

  1. State explicit fact grain.
  2. Build SQL that returns written premium, earned premium, and incurred claims by month and product_line.
  3. Explain one potential double-counting risk and mitigation.

Stated assumption: the reference joins claims onto premium months, so a claim booked in a month where its policy has no premium row would silently drop. The orphan-claim-month anti-join from the insurance data-quality audit is the check that keeps this assumption safe.

Assignment Query Workspace #

Loading SQL editor...

Grading Rubric #

  • 50% Correctness: grain-safe joins, correct aggregates
  • 25% Modeling clarity: explicit grain and assumptions
  • 25% Risk awareness: duplicate prevention and reconciliation approach
Warning

Automatic fail condition: query mixes incompatible grain without documenting a restatement/allocation strategy.