Skip to content

Commit

Permalink
utm to url renaming and documentation/docs updates
Browse files Browse the repository at this point in the history
  • Loading branch information
fivetran-joemarkiewicz committed Jun 29, 2022
1 parent df94819 commit 3c3ee0e
Show file tree
Hide file tree
Showing 7 changed files with 8 additions and 7 deletions.
6 changes: 3 additions & 3 deletions DECISIONLOG.md
Original file line number Diff line number Diff line change
Expand Up @@ -2,11 +2,11 @@
## Ads Associated with Multiple Ad Groups
It was discovered within the `google_ads.ads_stats` source table that a single Ad can be associated with multiple ad groups on any given day. Because of this, it was determined that the `is_most_recent_record` logic within the `stg_google_ads__ad_history` model needed to account for the `ad_group_id` as well as the individual `ad_id`. As a result, the most recent record of an ad could possibly contain a unique combination of the `ad_id` and the `ad_group_id`.

The final `google_ads__utm_report` and `google_ads__ad_report` models also take this into account and include an addition join condition between the `stg_google__ad_stats` and `stg_google__ad_history` models to account for the varying grain of the ad -> ad group relationship within the two tables. This additional join condition ensures the final models are accurately capturing **all** metrics for the ads that are associated with multiple ad groups.
The final `google_ads__url_report` and `google_ads__ad_report` models also take this into account and include an addition join condition between the `stg_google__ad_stats` and `stg_google__ad_history` models to account for the varying grain of the ad -> ad group relationship within the two tables. This additional join condition ensures the final models are accurately capturing **all** metrics for the ads that are associated with multiple ad groups.

This logic was only applied to the `google_ads__utm_report` and `google_ads__ad_report` models as it was discovered this relationship was unique to ads and ad groups. If you experience this relationship among any of the other ad hierarchies, please open and [issue](https://github.com/fivetran/dbt_google_ads/issues/new?assignees=&labels=bug%2Ctriage&template=bug-report.yml&title=%5BBug%5D+%3Ctitle%3E) and we can continue the discussion!
This logic was only applied to the `google_ads__url_report` and `google_ads__ad_report` models as it was discovered this relationship was unique to ads and ad groups. If you experience this relationship among any of the other ad hierarchies, please open and [issue](https://github.com/fivetran/dbt_google_ads/issues/new?assignees=&labels=bug%2Ctriage&template=bug-report.yml&title=%5BBug%5D+%3Ctitle%3E) and we can continue the discussion!

## UTM Report Filtering
This package contains a `google_ads__utm_report` which provides daily metrics for your utm compatible ads. It is important to note that not all Ads within Google's `ad_stats` report do not leverage utm parameters. Therefore, this package takes an opinionated approach to filter out any records that do not contain utm parameters or leverage a url within the ad.
This package contains a `google_ads__url_report` which provides daily metrics for your utm compatible ads. It is important to note that not all Ads within Google's `ad_stats` report do not leverage utm parameters. Therefore, this package takes an opinionated approach to filter out any records that do not contain utm parameters or leverage a url within the ad.

If you would like to leverage a report that contains all ads and their daily metrics, I would suggest you leverage the `google_ads__ad_report` which does not apply any filtering.
2 changes: 1 addition & 1 deletion README.md
Original file line number Diff line number Diff line change
Expand Up @@ -28,7 +28,7 @@ The following table provides a detailed list of all models materialized within t
| [google_ads__ad_group_report](https://fivetran.github.io/dbt_google_ads/#!/model/model.google_ads.google_ads__ad_group_report) | Each record in this table represents the daily performance at the ad group level. |
| [google_ads__keyword_report](https://fivetran.github.io/dbt_google_ads/#!/model/model.google_ads.google_ads__keyword_report) | Each record in this table represents the daily performance at the ad group level for keywords. |
| [google_ads__ad_report](https://fivetran.github.io/dbt_google_ads/#!/model/model.google_ads.google_ads__ad_report) | Each record in this table represents the daily performance at the ad level. |
| [google_ads__utm_report](https://fivetran.github.io/dbt_google_ads/#!/model/model.google_ads.google_ads__utm_report) | Each record in this table represents the daily performance of URLs at the ad level. |
| [google_ads__url_report](https://fivetran.github.io/dbt_google_ads/#!/model/model.google_ads.google_ads__url_report) | Each record in this table represents the daily performance of URLs at the ad level. |

# 🎯 How do I use the dbt package?

Expand Down
2 changes: 1 addition & 1 deletion docs/catalog.json

Large diffs are not rendered by default.

2 changes: 1 addition & 1 deletion docs/manifest.json

Large diffs are not rendered by default.

1 change: 1 addition & 0 deletions docs/run_results.json

Large diffs are not rendered by default.

2 changes: 1 addition & 1 deletion models/google_ads.yml
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
version: 2

models:
- name: google_ads__utm_report
- name: google_ads__url_report
description: Each record in this table represents the daily performance of URLs at the ad level.
tests:
- dbt_utils.unique_combination_of_columns:
Expand Down
File renamed without changes.

0 comments on commit 3c3ee0e

Please sign in to comment.