# Code Vintage Validity (which years a billing code is valid)

`medicare_silver.dim_code_validity` · Curated datasets · status live · 20,523 rows

For each billing code (HCPCS/CPT/DRG/etc.) the years it is valid: first_year, last_year, and the count of years observed. The reference that lets repricing resolve a claim's code against the RIGHT vintage and flag retired/not-yet-introduced codes instead of guessing — the code-vintage gap, now grounded in data (20,523 codes).

**Grain.** One row per (code, code_system) — first_year, last_year, year_count of validity.

| column | type | meaning |
|---|---|---|
| code | string |  |
| code_system | varchar(6) |  |
| first_year | bigint |  |
| last_year | bigint |  |
| year_count | bigint |  |

Query it: `query_substrate` with `SELECT ... FROM medicare_silver.dim_code_validity WHERE ... LIMIT 100`; read `describe_data_source("medicare_silver.dim_code_validity")` first.
