You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
I have searched the existing issues, and I could not find an existing issue for this bug
Current Behavior
When defining constraints on model-level in the schema.yml file and then executing dbt docs generate && dbt docs serve, the columns constraint is not set.
Expected Behavior
The CONSTRAINT value should be set to PK for this example.
More generally, the expected behavior should be that there is no difference between setting the constraints at the column level or at the model level for the presentation of the value within the dbt documentation.
Steps To Reproduce
Initiate and configure a dbt project with: dbt init
Add the model-level constraint to the my_first_dbt_model model:
constraints:
- type: primary_key
columns: [id]
Run dbt docs generate && dbt docs serve
The CONSTRAINT value is empty for the column id:
Relevant log output
No response
Environment
- OS: macOS Sequoia 15.2
- Python: 3.11.11
- dbt:
Core:
- installed: 1.9.1
- latest: 1.9.1 - Up to date!
Plugins:
- bigquery: 1.9.0 - Up to date!
Which database adapter are you using with dbt?
bigquery
Additional Context
No response
The text was updated successfully, but these errors were encountered:
Is this a new bug in dbt-core?
Current Behavior
When defining constraints on model-level in the
schema.yml
file and then executingdbt docs generate && dbt docs serve
, the columns constraint is not set.Expected Behavior
The CONSTRAINT value should be set to
PK
for this example.More generally, the expected behavior should be that there is no difference between setting the constraints at the column level or at the model level for the presentation of the value within the dbt documentation.
Steps To Reproduce
Initiate and configure a dbt project with:
dbt init
Add the model-level constraint to the
my_first_dbt_model
model:Run
dbt docs generate && dbt docs serve
The CONSTRAINT value is empty for the column
id
:Relevant log output
No response
Environment
Which database adapter are you using with dbt?
bigquery
Additional Context
No response
The text was updated successfully, but these errors were encountered: