Your first PRlesson 5 of 9

  1. set up
  2. pick data
  3. find source
  4. place it
  5. model
  6. YAML
  7. build
  8. PR
  9. merge

Write the model

A staging model is one SELECT from the raw model: explicit columns, light cleaning, renames to conventions. Here is the worked example — every choice in it is deliberate, and each explanation sits on the line it belongs to. Tap the numbers, then write yours:

stg_reference_opening_hours.sqltap a numbered line
    organisation_code,
    day_of_week,

step 1 of 3