You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Copy file name to clipboardExpand all lines: CHANGELOG.md
+34-4
Original file line number
Diff line number
Diff line change
@@ -1,9 +1,39 @@
1
-
# dbt_ad_reporting v1.UPDATE.UPDATE
1
+
# dbt_ad_reporting v1.4.0
2
2
3
-
## Under the Hood:
3
+
## 🎉 Feature Enhancement 🎉
4
+
- Added `ad_reporting__<report>_passthrough_metrics` variables to easily add common metrics across all platforms into the `ad_reporting` models! This allows metrics other than the standard `clicks`, `impressions`, and `cost` to be included in the final ad reporting models. See below for a full list of new variables and example metrics to passthrough. ([PR #85](https://github.com/fivetran/dbt_ad_reporting/pull/84))
5
+
- It is important to call out that this is only possible if the relevant upstream Ad platform variables have the same metric to be unioned in the roll up model. Please see the [README](https://github.com/fivetran/dbt_ad_reporting#optional-step-6-additional-configurations) section for details around how to configure the passthrough metrics.
6
+
- Please ensure you exercised due diligence when adding metrics to these models. The metrics added by default (`clicks`, `impressions`, and `cost`) have been vetted by the Fivetran team maintaining this package for accuracy. There are metrics included within the source reports, for example metric averages, which may be inaccurately represented at the grain for reports created in this package. You will want to ensure whichever metrics you pass through are indeed appropriate to aggregate at the respective reporting levels provided in this package.
7
+
```yml
8
+
vars:
9
+
ad_reporting__account_passthrough_metrics:
10
+
- name: conversions
11
+
- name: view_through_conversions
12
+
ad_reporting__campaign_passthrough_metrics:
13
+
- name: total_shares
14
+
- name: conversions
15
+
ad_reporting__ad_group_passthrough_metrics:
16
+
- name: conversions
17
+
- name: interactions
18
+
ad_reporting__ad_passthrough_metrics: ## For both Ad and URL reports
19
+
- name: conversions
20
+
- name: video_views_captured
21
+
ad_reporting__keyword_passthrough_metrics:
22
+
- name: interactions
23
+
ad_reporting__search_passthrough_metrics:
24
+
- name: conversions
25
+
- name: local_spend_amount
26
+
```
27
+
- Addition of the `pinterest__using_keywords` (default=`true`) variable that allows users to disable the relevant keyword reports in the downstream Pinterest models if they are not used. ([PR #89](https://github.com/fivetran/dbt_ad_reporting/pull/89))
28
+
29
+
## Under the Hood:
30
+
31
+
- Incorporated the new `fivetran_utils.drop_schemas_automation` macro into the end of each Buildkite integration test job. ([PR #86](https://github.com/fivetran/dbt_ad_reporting/pull/86))
32
+
- Updated the pull request [templates](/.github). ([PR #86](https://github.com/fivetran/dbt_ad_reporting/pull/86))
Copy file name to clipboardExpand all lines: README.md
+209-2
Original file line number
Diff line number
Diff line change
@@ -77,7 +77,7 @@ Include the following github package version in your `packages.yml`
77
77
```yaml
78
78
packages:
79
79
- package: fivetran/ad_reporting
80
-
version: [">=1.3.0", "<1.4.0"] # we recommend using ranges to capture non-breaking changes automatically
80
+
version: [">=1.4.0", "<1.5.0"] # we recommend using ranges to capture non-breaking changes automatically
81
81
```
82
82
83
83
Do NOT include the individual ad platform packages in this file. The ad reporting package itself has dependencies on these packages and will install them as well.
@@ -145,14 +145,17 @@ vars:
145
145
### Enable/Disable Specific Reports within Platforms
146
146
For **Apple Search Ads**, if you are not utilizing the search functionality, you may choose to update the respective variable below.
147
147
148
-
For **Twitter Ads**, if you are tracking keyword performance, you may choose to update the corresponding variable below.
148
+
For **Twitter Ads**, if you are not tracking keyword performance, you may choose to update the corresponding variable below.
149
+
150
+
For **Pinterest Ads**, if you are not tracking keyword performance, you may choose to update the corresponding variable below.
149
151
150
152
Add the following variables to your dbt_project.yml file
151
153
152
154
```yml
153
155
vars:
154
156
apple_search_ads__using_search_terms: False # by default this is assumed to be True
155
157
twitter_ads__using_keywords: False # by default this is assumed to be True
158
+
pinterest__using_keywords: False # by default this is assumed to be True
156
159
```
157
160
158
161
## (Recommended) Step 5: Change the Build Schema
@@ -225,6 +228,210 @@ models:
225
228
<details><summary>Expand for details</summary>
226
229
<br>
227
230
231
+
## Adding custom metrics to final reports
232
+
233
+
By default, this package selects `clicks`, `impressions`, and `cost` metrics from the upstream Ad platform reports. Additionally, each specific upstream Ad platform package allows for custom passthrough metrics to be included in the individual platform's final reports. You can find a complete list of available passthrough metric variables for each platform by referring to the relevant links below and inspecting the additional configurations for each platform:
Furthermore, this package allows you to include these configured upstream passthrough metrics in the final roll-up models of the combined Ad Reporting package. To include passthrough metrics in the respective final models, you need to define the following `ad_reporting__*` variables in your `dbt_project.yml` file:
247
+
248
+
```yml
249
+
vars:
250
+
ad_reporting__account_passthrough_metrics:
251
+
- name: conversions
252
+
- name: view_through_conversions
253
+
ad_reporting__campaign_passthrough_metrics:
254
+
- name: total_shares
255
+
- name: conversions
256
+
ad_reporting__ad_group_passthrough_metrics:
257
+
- name: conversions
258
+
- name: interactions
259
+
ad_reporting__ad_passthrough_metrics: ## For both Ad and URL reports
260
+
- name: conversions
261
+
- name: video_views_captured
262
+
ad_reporting__keyword_passthrough_metrics:
263
+
- name: interactions
264
+
ad_reporting__search_passthrough_metrics:
265
+
- name: conversions
266
+
- name: local_spend_amount
267
+
```
268
+
It is important to ensure that if you want to configure a passthrough metric for an ad reporting end model, that metric **must** be included in all of your upstream variables. Additionally, the name of the metric **must** be consistent across platforms. If a certain upstream platform does not include the metric you **must** include a `transform_sql` argument to pass a null value through (see below for examples). The following configuration is an example when using the Microsoft Ads, Apple Search Ads, Google Ads, Snapchat Ads, TikTok Ads, and Reddit Ads platforms within a `dbt_project.yml` file:
269
+
270
+
>**Note**: Please ensure you exercised due diligence when adding metrics to these models. The metrics added by default (`clicks`, `impressions`, and `cost`) have been vetted by the Fivetran team maintaining this package for accuracy. There are metrics included within the source reports, for example metric averages, which may be inaccurately represented at the grain for reports created in this package. You will want to ensure whichever metrics you pass through are indeed appropriate to aggregate at the respective reporting levels provided in this package.
271
+
272
+
>**Note**: While the below configuration is only for a subset of Ad platforms, the same strategy will be used for all other possible combinations of upstream Ad platform dependencies.
273
+
274
+
```yml
275
+
vars:
276
+
## Account Report Passthrough Metrics
277
+
microsoft_ads__account_passthrough_metrics:
278
+
- name: conversions
279
+
- name: view_through_conversions
280
+
transform_sql: "null"
281
+
apple_search_ads__campaign_passthrough_metrics:
282
+
- name: conversions
283
+
- name: view_through_conversions
284
+
transform_sql: "null"
285
+
- name: total_shares
286
+
transform_sql: "null"
287
+
google_ads__account_stats_passthrough_metrics:
288
+
- name: conversions
289
+
- name: view_through_conversions
290
+
# snapchat_ads__ad_hourly_passthrough_metrics: # Defined below in the ad/url metrics therefore, not needed here but kept for documentation.
transform_sql: "cast(local_spend_amount as int64)"
428
+
- name: conversions
429
+
transform_sql: "null"
430
+
ad_reporting__search_passthrough_metrics:
431
+
- name: conversions
432
+
- name: local_spend_amount
433
+
```
434
+
228
435
## Disabling null URL filtering from URL reports
229
436
The default behavior for the `ad_reporting__url_report` end model is to filter out records having null URL fields, however, you are able to turn off this filter if needed. To turn off the filter, include the below in your `dbt_project.yml` file. This variable will affect ALL Fivetran platform packages enabled in Ad Reporting, therefore either all URL reports will have null URLs filtered, or all URL reports will have null URLs included.
0 commit comments