Skip to content

Commit

Permalink
Fix SQL schema selection in default-sql template (databricks#1471)
Browse files Browse the repository at this point in the history
## Changes

This fixes a last-minute regression that snuck into
databricks#1463: unfortunately we need to
use `USE IDENTIFIER('schema')` to select a schema for now. In the future
we expect we can just use `USE SCHEMA 'schema'`.
  • Loading branch information
lennartkats-db authored Jun 4, 2024
1 parent f8b2cb8 commit 4bc0ea0
Show file tree
Hide file tree
Showing 2 changed files with 2 additions and 2 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@
{{- /* We can't use a materialized view here since they don't support 'create or refresh' yet.*/}}

USE CATALOG {{"{{"}}catalog{{"}}"}};
USE {{"{{"}}schema{{"}}"}};
USE IDENTIFIER({{"{{"}}schema{{"}}"}});

CREATE OR REPLACE VIEW
orders_daily
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@
-- See also https://docs.databricks.com/sql/language-manual/sql-ref-syntax-ddl-create-streaming-table.html

USE CATALOG {{"{{"}}catalog{{"}}"}};
USE {{"{{"}}schema{{"}}"}};
USE IDENTIFIER({{"{{"}}schema{{"}}"}});

CREATE OR REFRESH STREAMING TABLE
orders_raw
Expand Down

0 comments on commit 4bc0ea0

Please sign in to comment.