diff --git a/models/staging/stg_metering_history.sql b/models/staging/stg_metering_history.sql index ca8c3d1..1816b59 100644 --- a/models/staging/stg_metering_history.sql +++ b/models/staging/stg_metering_history.sql @@ -1,6 +1,5 @@ {{ config( - materialized='incremental', - unique_key=['service_type', 'start_time', 'entity_id'], + materialized='table' ) }} select @@ -13,10 +12,4 @@ select credits_used_cloud_services, credits_used from {{ source('snowflake_account_usage', 'metering_history') }} - -{% if is_incremental() %} - -- account for changing metering data - where end_time > (select coalesce(dateadd(day, -7, max(end_time)), '1970-01-01') from {{ this }}) -{% endif %} - order by start_time asc