Skip to content

Commit

Permalink
More fixes for Bigquery
Browse files Browse the repository at this point in the history
  • Loading branch information
bvkabn committed Sep 20, 2024
1 parent 06bdd72 commit d189c98
Show file tree
Hide file tree
Showing 2 changed files with 19 additions and 19 deletions.
2 changes: 1 addition & 1 deletion models/sources/model_executions.sql
Original file line number Diff line number Diff line change
Expand Up @@ -13,7 +13,7 @@ select
cast(null as {{ type_float() }}) as total_node_runtime,
cast(null as {{ type_int() }}) as rows_affected,
{% if target.type == "bigquery" %}
, cast(null as {{ type_int() }}) as bytes_processed
cast(null as {{ type_int() }}) as bytes_processed,
{% endif %}
cast(null as {{ type_string() }}) as materialization,
cast(null as {{ type_string() }}) as {% if target.type == "sqlserver" %} "schema"
Expand Down
36 changes: 18 additions & 18 deletions models/sources/seeds.sql
Original file line number Diff line number Diff line change
@@ -1,23 +1,23 @@
/* Bigquery won't let us `where` without `from` so we use this workaround */
with
dummy_cte as (

select 1 as foo

)
with dummy_cte as (select 1 as foo)

select
cast(null as {{ type_string() }}) as command_invocation_id
, cast(null as {{ type_string() }}) as node_id
, cast(null as {{ type_timestamp() }}) as run_started_at
, cast(null as {{ type_string() }}) as "database"
, cast(null as {{ type_string() }}) as "schema"
, cast(null as {{ type_string() }}) as name
, cast(null as {{ type_string() }}) as package_name
, cast(null as {{ type_string() }}) as path
, cast(null as {{ type_string() }}) as checksum
, cast(null as {{ type_json() }}) as meta
, cast(null as {{ type_string() }}) as alias
, cast(null as {{ type_json() }}) as all_results
cast(null as {{ type_string() }}) as command_invocation_id,
cast(null as {{ type_string() }}) as node_id,
cast(null as {{ type_timestamp() }}) as run_started_at,
cast(null as {{ type_string() }}) as {% if target.type == "sqlserver" %} "database"
{% else %} database
{% endif %},
cast(null as {{ type_string() }}) as {% if target.type == "sqlserver" %} "schema"
{% else %} schema
{% endif %},
cast(null as {{ type_string() }}) as name,
cast(null as {{ type_string() }}) as package_name,
cast(null as {{ type_string() }}) as path,
cast(null as {{ type_string() }}) as checksum,
cast(null as {{ type_json() }}) as meta,
cast(null as {{ type_string() }}) as alias,
cast(null as {{ type_json() }}) as all_results
from dummy_cte
where 1 = 0

0 comments on commit d189c98

Please sign in to comment.