Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
1 change: 1 addition & 0 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
Expand Up @@ -9,6 +9,7 @@
- Fix `workflow_job` Python model submission method failing with dictionary attribute error ([#1360](https://github.com/databricks/dbt-databricks/issues/1360))
- Fix `TestWorkflowJob` functional test that was unreachable on all profiles due to incorrect skip list, wrong model fixture, and invalid `max_retries` parameter ([#1360](https://github.com/databricks/dbt-databricks/issues/1360))
- Fix column order mismatch in microbatch and replace_where incremental strategies by using INSERT BY NAME syntax ([#1338](https://github.com/databricks/dbt-databricks/issues/1338))
- Fix `dbt run --empty` failing with inline `ref()` / `source()` aliases ([dbt-labs/dbt-adapters#660](https://github.com/dbt-labs/dbt-adapters/issues/660))

## dbt-databricks 1.11.6 (Mar 10, 2026)

Expand Down
1 change: 1 addition & 0 deletions dbt/adapters/databricks/relation.py
Original file line number Diff line number Diff line change
Expand Up @@ -72,6 +72,7 @@ class DatabricksRelation(BaseRelation):
quote_policy: Policy = field(default_factory=lambda: DatabricksQuotePolicy())
include_policy: Policy = field(default_factory=lambda: DatabricksIncludePolicy())
quote_character: str = "`"
require_alias: bool = False
is_delta: Optional[bool] = None
create_constraints: list[TypedConstraint] = field(default_factory=list)
alter_constraints: list[TypedConstraint] = field(default_factory=list)
Expand Down
Empty file.
9 changes: 9 additions & 0 deletions tests/functional/adapter/empty/test_empty.py
Original file line number Diff line number Diff line change
@@ -0,0 +1,9 @@
from dbt.tests.adapter.empty.test_empty import BaseTestEmpty, BaseTestEmptyInlineSourceRef


class TestDatabricksEmpty(BaseTestEmpty):
pass


class TestDatabricksEmptyInlineSourceRef(BaseTestEmptyInlineSourceRef):
pass
13 changes: 13 additions & 0 deletions tests/unit/test_relation.py
Original file line number Diff line number Diff line change
Expand Up @@ -368,3 +368,16 @@ def test_render_constraints_for_create__with_constraints(
relation.add_constraint(custom_constraint)
relation.add_constraint(pk_constraint)
assert relation.render_constraints_for_create() == "a > 1, PRIMARY KEY (a)"


class TestDatabricksRenderLimited:
def test_render_limited_with_empty_no_alias(self):
relation = DatabricksRelation.create(
database="test_catalog",
schema="test_schema",
identifier="test_model",
limit=0,
)
result = relation.render_limited()
expected = "(select * from `test_catalog`.`test_schema`.`test_model` where false limit 0)"
assert result == expected
Loading