Skip to content

fix: unset column tags before dropping a column#1597

Draft
saishreeeee wants to merge 2 commits into
databricks:mainfrom
saishreeeee:PECOBLR-3702
Draft

fix: unset column tags before dropping a column#1597
saishreeeee wants to merge 2 commits into
databricks:mainfrom
saishreeeee:PECOBLR-3702

Conversation

@saishreeeee

Copy link
Copy Markdown
Contributor

Resolves #1323

Description

Dropping a column that carries a governed tag fails with CANNOT_DROP_TAGGED_COLUMN, because Unity Catalog requires the tag be removed before the column. This unsets any tags on the columns being dropped (via on_schema_change='sync_all_columns') before issuing DROP COLUMNS, so tagged columns can be dropped cleanly.

Checklist

  • I have run this code in development and it appears to resolve the stated issue
  • This PR includes tests, or tests are not required/relevant for this PR
  • I have updated the CHANGELOG.md and added information about my change to the "dbt-databricks next" section.
  • [Optional] I have run /dbt-databricks-pr-ready (AI agent skill in .claude/skills/) and addressed its merge-readiness feedback

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

Remove governed tags before dropping a column

1 participant