PR #22 includes the following updates:
- Upstream Breaking Change: In the July 2023 TikTok Ads connector update for the
ADGROUP_HISTORY
table, theage
column was renamed toage_groups
.- This change primarily affects the upstream
stg_tiktok_ads__ad_group_history
model indbt_tiktok_source
. Theage_groups
column was not previously used in any downstream models withindbt_tiktok_ads
, so this change impacts only the upstream staging model. - Previously, we coalesced the
age
andage_groups
columns in thestg_tiktok_ads__ad_group_history
model to accommodate connectors using the old naming convention. However, due to inconsistent data types, this approach is no longer viable. - As a result, the coalesced field has been removed in favor of the
age_groups
column. - If necessary, you can populate historical data in the
age_groups
column by performing a resync of theADGROUP_HISTORY
table, as TikTok provides all data regardless of the previous sync state. - For more details, see the DECISIONLOG entry.
- This change primarily affects the upstream
- Added
DECISIONLOG
file:- Detailed the removal of the previously mentioned coalesced
age
andage_groups
column. - Clarified why aggregation differences occur across varying grains.
- Detailed the removal of the previously mentioned coalesced
PR #20 includes the following BREAKING CHANGE updates:
-
We have added the following source fields to each
tiktok_ads
end model (note that theconversion
field was already present):real_time_conversion
: Number of times your ad resulted in the optimization event and timeframe you selected.total_purchase_value
: The total value of purchase events that occurred in your app that were recorded by your measurement partner.total_sales_lead_value
: The monetary worth or potential value assigned to a lead generated through ads.total_conversion_value
: The accumulated value oftotal_purchase_value
andtotal_sales_lead_value
.
-
In the event that you were already passing the above fields in via our passthrough columns, the package will dynamically avoid "duplicate column" errors.
The above new field additions are breaking changes for users who were not already bringing in conversion fields via passthrough columns.
- Created
tiktok_ads_persist_pass_through_columns
macro to ensure that the new conversion fields are backwards compatible with users who have already included them via passthrough fields. - Updated
conversion
field to be an integer rather than a numeric data type in thetiktok_ads_source
package, as is the expected behavior of the field. This is a breaking change. - Added integrity and consistency validation tests within
integration_tests
folder for the transformation models (to be used by maintainers only). - Updated seed data to adequately test new field additions in integration tests.
PR #13 includes the following updates:
- Updated the source identifier format for consistency with other packages and for compatibility with the
fivetran_utils.union_data
macro. Identifiers now are:
current | previous |
---|---|
tiktok_ads_adgroup_history_identifier | tiktok_ads__ad_group_history_identifier |
tiktok_ads_ad_history_identifier | tiktok_ads__ad_history_identifier |
tiktok_ads_advertiser_identifier | tiktok_ads__advertiser_identifier |
tiktok_ads_campaign_history_identifier | tiktok_ads__campaign_history_identifier |
tiktok_ads_ad_report_hourly_identifier | tiktok_ads__ad_report_hourly_identifier |
tiktok_ads_adgroup_report_hourly_identifier | tiktok_ads__ad_group_report_hourly_identifier |
tiktok_ads_campaign_report_hourly_identifier | tiktok_ads__campaign_report_hourly_identifier |
- If you are using the previous identifier, be sure to update to the current version!
- Unioning capability! This adds the ability to union source data from multiple tiktok_ads connectors. Refer to the Union Multiple Connectors README section for more details.
- In the source package, updated tmp models to union source data using the
fivetran_utils.union_data
macro. - To distinguish which source each field comes from, added
source_relation
column in each staging and downstream model and applied thefivetran_utils.source_relation
macro.- The
source_relation
column is included in all joins in the transform package.
- The
- Updated tests to account for the new
source_relation
column.
PR #11 includes the following changes:
- In the July 2023 connector update for TikTok Ads, the connector was updated to support the TikTok Ads v1.3 API. As a result breaking changes exist within the dependent v0.4.0 dbt_tiktok_ads_source release in addition to the following breaking changes within this package release:
Updated model | Removed fields |
---|---|
tiktok_ads__ad_group_report | action_categories , age , languages , interest_category |
tiktok_ads__ad_report | action_categories , age , languages , interest_category |
tiktok_ads__url_report | action_categories , age , languages , interest_category |
Note: All of the above fields were also removed due to complications with the BigQuery JSON datatype causing errors during compilation.
- Incorporated the new
fivetran_utils.drop_schemas_automation
macro into the end of each Buildkite integration test job. - Updated the pull request templates.
PR #7 includes the following breaking changes:
- Dispatch update for dbt-utils to dbt-core cross-db macros migration. Specifically
{{ dbt_utils.<macro> }}
have been updated to{{ dbt.<macro> }}
for the below macros:any_value
bool_or
cast_bool_to_text
concat
date_trunc
dateadd
datediff
escape_single_quotes
except
hash
intersect
last_day
length
listagg
position
replace
right
safe_cast
split_part
string_literal
type_bigint
type_float
type_int
type_numeric
type_string
type_timestamp
array_append
array_concat
array_construct
- For
current_timestamp
andcurrent_timestamp_in_utc
macros, the dispatch AND the macro names have been updated to the below, respectively:dbt.current_timestamp_backcompat
dbt.current_timestamp_in_utc_backcompat
packages.yml
has been updated to reflect new defaultfivetran/fivetran_utils
version, previously[">=0.3.0", "<0.4.0"]
now[">=0.4.0", "<0.5.0"]
.
- For use in the dbt_ad_reporting package, users can now allow records having nulls in url fields to be included in the
ad_reporting__url_report
model. See the dbt_ad_reporting README for more details. PR #8
- Disabled the
not_null
test fortiktok_ads__url_report
when null urls are allowed. PR #8
This PR (#6) updates the source package version.
This PR (#5) applies the following updates to provide further flexibility in your ad reporting. Additionally, these new end models will be leveraged in the respective downstream dbt_ad_reporting models.
- Updates
ad_group_hourly
variable toad_group_report_hourly
- Removes intermediate models and instead incorporates previous logic into end models
- Renames the
tikok_ads__ad_adapter
model totiktok_ads__url_report
- Removes dependency of models on the
tikok_ads__ad_adapter
model and moves that previous logic into each model, using corresponding hourly reports for each model's granularity (e.g.tikok_ads__campaign_report
now uses thecampaign_report_hourly
)
- Adds in the following models and respective field descriptions and tests:
tiktok_ads__account_report
tiktok_ads__url_report
tiktok_ads__ad_report
- Adds additional fields to existing models
ad_group_report
andcampaign_report
that were previously not brought in - Inclusion of passthrough metrics:
tiktok_ads__ad_group_hourly_passthrough_metrics
tiktok_ads__ad_hourly_passthrough_metrics
tiktok_ads__campaign_hourly_passthrough_metrics
This applies to all passthrough columns within the
dbt_tiktok_ads
package and not just thetiktok_ads__ad_group_hourly_passthrough_metrics
example.
vars:
tiktok_ads__ad_group_hourly_passthrough_metrics:
- name: "my_field_to_include" # Required: Name of the field within the source.
alias: "field_alias" # Optional: If you wish to alias the field within the staging model.
- Adds not-null tests to key fields
- Applies standardization updates
- Add enable configs for this specific ad platform, for use in the Ad Reporting rollup package
- Updated package yml to point to live source
- This is the initial release of this package. For more information refer to the README.
- Aggregating daily metrics: As best practice, we try using the most granular data to perform aggregations. Therefore metrics such as
spend
anddaily_cpc
for each day is aggregated using the hourly source tables rather than daily source tables. In addition, aggregations done per ad group and per campaign is done using the ad table.