Reference table (allowed categories)¶
string_reference_table - Column-level - String
Validates that non-null values exist in a reference table's column - a foreign key for string categories.
Parameters¶
| Parameter | Type | Default | Required | Description |
|---|---|---|---|---|
reference_table |
str | none | Yes | Fully qualified table name holding the allowed values, e.g. schema.dim_states. |
reference_column |
str | none | Yes | Column in the reference table holding the allowed values. |
threshold_percent |
float | 0.0 |
No | Fail if the percentage of values not in the reference table exceeds this. |
YAML example¶
checks:
- name: example_string_reference_table
check_type: string_reference_table
table_name: schema.table
column_name: example_column
parameters:
reference_table: <reference_table>
reference_column: <reference_column>
threshold_percent: 0.0
See YAML check format for the full field reference.