Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Bethanyhipple dbtlabs patch 1 #92

Closed
wants to merge 9 commits into from
Closed
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: 0 additions & 1 deletion models/_samples/snapshot/_snapshot__models.yml
Original file line number Diff line number Diff line change
Expand Up @@ -5,5 +5,4 @@ models:
columns:
- name: surrogate_key
tests:
- unique
- not_null
1 change: 0 additions & 1 deletion models/staging/stripe/stg_stripe__payments.sql
Original file line number Diff line number Diff line change
@@ -1,5 +1,4 @@
-- example showing staging model after snapshot

select
-- ids
id as payment_id,
Expand Down
4 changes: 4 additions & 0 deletions models/staging/stripe/stg_stripe__payments.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,4 @@
models:
- name: stg_stripe__payments
access: public
description: description
4 changes: 2 additions & 2 deletions packages.yml
Original file line number Diff line number Diff line change
Expand Up @@ -4,10 +4,10 @@ packages:
- package: dbt-labs/dbt_utils
version: 1.1.0
- package: dbt-labs/audit_helper
version: 0.9.0
version: 0.12.0
- package: brooklyn-data/dbt_artifacts
version: 2.6.2
- package: dbt-labs/dbt_project_evaluator
version: 0.6.0
- package: calogica/dbt_expectations
version: 0.8.5
version: 0.8.5
7 changes: 4 additions & 3 deletions snapshots/snapshot_int_line_items.sql
Original file line number Diff line number Diff line change
Expand Up @@ -10,13 +10,14 @@
{{
config(
target_database='analytics',
target_schema=var('example_target_snapshot_schema'),
target_schema='dbt_bhipple',
unique_key='order_item_id',
strategy='check',
check_cols=['gross_item_sales_amount', 'net_item_sales_amount'],
)
}}

select * from {{ ref('int_line_items_amounts_calculated') }}
select row_number() over(order by order_item_id) as row_id, * from {{ ref('int_line_items_amounts_calculated') }}
order by row_id
{% endsnapshot %}

{% endsnapshot %}