Skip to content

Commit

Permalink
dbt: add OSO events mart (#2022)
Browse files Browse the repository at this point in the history
  • Loading branch information
ccerv1 authored Aug 30, 2024
1 parent 32dcd64 commit 92020cd
Showing 1 changed file with 33 additions and 0 deletions.
33 changes: 33 additions & 0 deletions warehouse/dbt/models/marts/events/oso_events_v0.sql
Original file line number Diff line number Diff line change
@@ -0,0 +1,33 @@
{#
Grab all events associated with OSO (the project)
#}


{{
config(
materialized='table'
)
}}

select
int_events.time,
int_events.event_source,
int_events.event_source_id,
int_events.event_type,
int_events.to_artifact_id,
int_events.to_artifact_namespace,
int_events.to_artifact_name,
int_events.to_artifact_type,
int_events.to_artifact_source_id,
int_events.from_artifact_id,
int_events.from_artifact_namespace,
int_events.from_artifact_name,
int_events.from_artifact_type,
int_events.from_artifact_source_id,
int_events.amount
from {{ ref('int_events') }}
inner join {{ ref('int_artifacts_by_project') }}
on
int_events.to_artifact_id
= int_artifacts_by_project.artifact_id
where int_artifacts_by_project.project_name = 'opensource-observer'

0 comments on commit 92020cd

Please sign in to comment.