Documentation · rule model-date-ambiguous
dbt models with several dates and no default
A Metacenta review checks this under the rule Core models with several dates say which is which. Everything below applies whether or not you ever commission one.
What this rule checks
This rule looks at each core model that declares two or more date columns. It flags the model when none of those dates has a description. A model counts as core when a dbt exposure, Looker explore or Tableau view depends on it. If none is declared, the marts count instead. A column counts as a date by its type, or by a name such as _date, _at or _ts.
Why it matters
A total by month needs one date. With three undescribed dates, a person asks which one is meant; an AI agent picks one. Two picks give two totals for the same month, and both look right.
How to fix it
Say which date each main table reports by. Describe each date column: the event it records and its time zone. Say which date is the default for reporting, so a reader who needs one knows where to start.
Before:
columns:
- name: order_date
- name: shipped_at
- name: settled_ts
After:
columns:
- name: order_date
description: Date the customer placed the order (UTC). Report revenue by this.
- name: shipped_at
description: When the parcel left the warehouse (UTC).
- name: settled_ts
description: When the payment provider settled the charge (UTC).
When it is fine to leave
One described date is enough to pass, because a reader then has a default. Audit timestamps such as _loaded_at can stay undescribed if the reporting date is described.
What we need to check it
manifest.json. Consumers come from exposures in the manifest, or from LookML or Tableau files if you share them. A date found by its name is medium confidence; one typed as a date is high.