From 1779d05dfdb3609d872ba425cea8f3ee0b25f6f9 Mon Sep 17 00:00:00 2001 From: IVAN VALENZUELA UTRERA Date: Thu, 19 Dec 2024 15:37:27 +0000 Subject: [PATCH 1/2] fix: Added headers to explores. Edited headers of views to remove unneeded information. Hide not relevant explores. --- explores/fb_ads.explore.lkml | 13 +++---------- explores/goals_campaigns.explore.lkml | 3 +++ explores/google_ads.explore.lkml | 6 ++---- explores/pacing_block.explore.lkml | 5 +---- views/fb_ads_views/base_views/ad_accounts.view.lkml | 3 --- views/fb_ads_views/base_views/ad_insights.view.lkml | 3 --- .../base_views/ad_insights_actions.view.lkml | 3 --- views/goals/campaigns_flat_goals.view.lkml | 3 --- views/goals/campaigns_info.view.lkml | 3 +++ .../base_views/google_ads_ad.view.lkml | 3 --- .../base_views/google_ads_campaign.view.lkml | 3 --- .../google_ads_campaign_basic_stats.view.lkml | 4 ++++ .../base_views/google_ads_customer.view.lkml | 3 --- .../base_views/google_ads_group.view.lkml | 3 --- .../base_views/google_ads_stats.view.lkml | 4 ---- views/pacing_block/multisource_ads.view.lkml | 3 --- 16 files changed, 16 insertions(+), 49 deletions(-) diff --git a/explores/fb_ads.explore.lkml b/explores/fb_ads.explore.lkml index ded863f..8e745b3 100644 --- a/explores/fb_ads.explore.lkml +++ b/explores/fb_ads.explore.lkml @@ -1,7 +1,4 @@ ##################################################################### -# Owners: cesarenrique@, ivanantonio@, agregori@, edherivan@ -# Contact Method: Gchat/e-mail -# Created Date: # Purpose: Contains the Facebook Ads Explores joined by relevant views and fields. ##################################################################### @@ -25,12 +22,8 @@ explore: ad_insights { } } -explore: ad_accounts { - hidden:yes - } +explore: ad_accounts {hidden:yes} -explore: ad_insights_actions { - hidden: yes -} +explore: ad_insights_actions {hidden: yes} -explore: dt_fb_ads {} +explore: dt_fb_ads {hidden:yes} diff --git a/explores/goals_campaigns.explore.lkml b/explores/goals_campaigns.explore.lkml index b8bf753..1af2789 100644 --- a/explores/goals_campaigns.explore.lkml +++ b/explores/goals_campaigns.explore.lkml @@ -1,3 +1,6 @@ +##################################################################### +# Purpose: Contains the Goal Explore created from GSheets derived table joined to the multisource_ads Explore. +##################################################################### include: "/views/goals/campaigns_flat_goals.view.lkml" include: "/views/pacing_block/multisource_ads.view.lkml" diff --git a/explores/google_ads.explore.lkml b/explores/google_ads.explore.lkml index b8a4d24..b867fb5 100644 --- a/explores/google_ads.explore.lkml +++ b/explores/google_ads.explore.lkml @@ -1,7 +1,4 @@ ##################################################################### -# Owners: cesarenrique@, ivanantonio@, agregori@, edherivan@ -# Contact Method: Gchat/e-mail -# Created Date: # Purpose: Contains the Google Ads Explore joined by relevant views and fields. ##################################################################### @@ -38,6 +35,7 @@ explore: GAds { } explore: CampaignBasicStats { + hidden: yes from: google_ads_campaign_basic_stats label: "Google Ads Campaigns Stats" join: google_ads_campaign { @@ -47,4 +45,4 @@ explore: CampaignBasicStats { } } -explore: dt_google_ads {} +explore: dt_google_ads {hidden:yes} diff --git a/explores/pacing_block.explore.lkml b/explores/pacing_block.explore.lkml index 31196ef..82623dd 100644 --- a/explores/pacing_block.explore.lkml +++ b/explores/pacing_block.explore.lkml @@ -1,7 +1,4 @@ ##################################################################### -# Owners: cesarenrique@, ivanantonio@, agregori@, edherivan@ -# Contact Method: Gchat/e-mail -# Created Date: # Purpose: Contains the Multisource Ads Explore. ##################################################################### @@ -13,4 +10,4 @@ explore: multisource_ads {} explore: forecast {} -explore: training {} +explore: training {hidden: yes} diff --git a/views/fb_ads_views/base_views/ad_accounts.view.lkml b/views/fb_ads_views/base_views/ad_accounts.view.lkml index cc5046d..9bd92f6 100644 --- a/views/fb_ads_views/base_views/ad_accounts.view.lkml +++ b/views/fb_ads_views/base_views/ad_accounts.view.lkml @@ -1,7 +1,4 @@ ##################################################################### -# Owners: cesarenrique@, ivanantonio@, edherivan@ -# Contact Method: Gchat/e-mail -# Created Date: # Purpose: Contains information about Ad Accounts from Facebook to use for # Data Analysis, this table represents a business, person or other entity who creates and manages ads on Facebook. # Multiple people can manage an account, and each person can have one or more levels of access to an account diff --git a/views/fb_ads_views/base_views/ad_insights.view.lkml b/views/fb_ads_views/base_views/ad_insights.view.lkml index 75c7fe9..05f1c57 100644 --- a/views/fb_ads_views/base_views/ad_insights.view.lkml +++ b/views/fb_ads_views/base_views/ad_insights.view.lkml @@ -1,7 +1,4 @@ ##################################################################### -# Owners: cesarenrique@, ivanantonio@, edherivan@ -# Contact Method: Gchat/e-mail -# Created Date: # Purpose: Contains information about Ad insights from Facebook to use for # Data Analysis. The Insights API can return several metrics which are estimated or in-development. # In some cases a metric may be both estimated and in-development. diff --git a/views/fb_ads_views/base_views/ad_insights_actions.view.lkml b/views/fb_ads_views/base_views/ad_insights_actions.view.lkml index b42df57..1415b2d 100644 --- a/views/fb_ads_views/base_views/ad_insights_actions.view.lkml +++ b/views/fb_ads_views/base_views/ad_insights_actions.view.lkml @@ -1,7 +1,4 @@ ##################################################################### -# Owners: cesarenrique@, ivanantonio@, edherivan@ -# Contact Method: Gchat/e-mail -# Created Date: # Purpose: Contains information about Ad insights Actions from Facebook to use for # Data Analysis. The Insights Actions API can return several metrics which are estimated or in-development. # In some cases a metric may be both estimated and in-development. diff --git a/views/goals/campaigns_flat_goals.view.lkml b/views/goals/campaigns_flat_goals.view.lkml index cad988e..cd8bd32 100644 --- a/views/goals/campaigns_flat_goals.view.lkml +++ b/views/goals/campaigns_flat_goals.view.lkml @@ -1,7 +1,4 @@ ##################################################################### -# Owners: cesarenrique@, ivanantonio@, edherivan@ -# Contact Method: Gchat/e-mail -# Created Date: # Purpose: Creates a derived table that uses the fields defined in sheets template to use as a track performance of ads campaings across sources. ##################################################################### diff --git a/views/goals/campaigns_info.view.lkml b/views/goals/campaigns_info.view.lkml index c83e971..9ed85e5 100644 --- a/views/goals/campaigns_info.view.lkml +++ b/views/goals/campaigns_info.view.lkml @@ -1,3 +1,6 @@ +##################################################################### +# Purpose: Creates a derived table that uses the fields defined in manifest file to use as a track performance of ads campaings across sources. +##################################################################### view: campaigns_info { derived_table: { sql: diff --git a/views/google_ads_views/base_views/google_ads_ad.view.lkml b/views/google_ads_views/base_views/google_ads_ad.view.lkml index 1516ccf..60c7a7d 100644 --- a/views/google_ads_views/base_views/google_ads_ad.view.lkml +++ b/views/google_ads_views/base_views/google_ads_ad.view.lkml @@ -1,7 +1,4 @@ ##################################################################### -# Owners: cesarenrique@, ivanantonio@, edherivan@ -# Contact Method: Gchat/e-mail -# Created Date: # Purpose: Created from Google Ads Transfer, specifically from Ads Ad table. ##################################################################### diff --git a/views/google_ads_views/base_views/google_ads_campaign.view.lkml b/views/google_ads_views/base_views/google_ads_campaign.view.lkml index 29a361f..8043f84 100644 --- a/views/google_ads_views/base_views/google_ads_campaign.view.lkml +++ b/views/google_ads_views/base_views/google_ads_campaign.view.lkml @@ -1,7 +1,4 @@ ##################################################################### -# Owners: cesarenrique@, ivanantonio@, edherivan@ -# Contact Method: Gchat/e-mail -# Created Date: # Purpose: Created from Google Ads Transfer, specifically from Ads Campaign table. ##################################################################### diff --git a/views/google_ads_views/base_views/google_ads_campaign_basic_stats.view.lkml b/views/google_ads_views/base_views/google_ads_campaign_basic_stats.view.lkml index 920132f..b04ef32 100644 --- a/views/google_ads_views/base_views/google_ads_campaign_basic_stats.view.lkml +++ b/views/google_ads_views/base_views/google_ads_campaign_basic_stats.view.lkml @@ -1,3 +1,7 @@ +##################################################################### +# Purpose: Created from Google Ads Transfer, specifically from Ads Campaign Basic Stats table. +##################################################################### + view: google_ads_campaign_basic_stats { sql_table_name: `@{PROJECT_ID}.@{GADS_DATASET_NAME}.ads_CampaignBasicStats_@{GADS_CUSTOMER_ID}` ;; diff --git a/views/google_ads_views/base_views/google_ads_customer.view.lkml b/views/google_ads_views/base_views/google_ads_customer.view.lkml index 4b66819..fef2d12 100644 --- a/views/google_ads_views/base_views/google_ads_customer.view.lkml +++ b/views/google_ads_views/base_views/google_ads_customer.view.lkml @@ -1,7 +1,4 @@ ##################################################################### -# Owners: cesarenrique@, ivanantonio@, edherivan@ -# Contact Method: Gchat/e-mail -# Created Date: # Purpose: Created from Google Ads Transfer, specifically from Ads Customer table. ##################################################################### view: google_ads_customer { diff --git a/views/google_ads_views/base_views/google_ads_group.view.lkml b/views/google_ads_views/base_views/google_ads_group.view.lkml index 3a20281..915996b 100644 --- a/views/google_ads_views/base_views/google_ads_group.view.lkml +++ b/views/google_ads_views/base_views/google_ads_group.view.lkml @@ -1,7 +1,4 @@ ##################################################################### -# Owners: cesarenrique@, ivanantonio@, edherivan@ -# Contact Method: Gchat/e-mail -# Created Date: # Purpose: Created from Google Ads Transfer, specifically from Ads Group table. ##################################################################### diff --git a/views/google_ads_views/base_views/google_ads_stats.view.lkml b/views/google_ads_views/base_views/google_ads_stats.view.lkml index e16d79d..7c32d37 100644 --- a/views/google_ads_views/base_views/google_ads_stats.view.lkml +++ b/views/google_ads_views/base_views/google_ads_stats.view.lkml @@ -1,11 +1,7 @@ ##################################################################### -# Owners: cesarenrique@, ivanantonio@, edherivan@ -# Contact Method: Gchat/e-mail -# Created Date: # Purpose: Created from Google Ads Transfer, specifically from Ads Stats table. ##################################################################### - view: google_ads_stats { sql_table_name: `@{PROJECT_ID}.@{GADS_DATASET_NAME}.ads_AdStats_@{GADS_CUSTOMER_ID}` ;; diff --git a/views/pacing_block/multisource_ads.view.lkml b/views/pacing_block/multisource_ads.view.lkml index 480b40d..da993a3 100644 --- a/views/pacing_block/multisource_ads.view.lkml +++ b/views/pacing_block/multisource_ads.view.lkml @@ -1,7 +1,4 @@ ##################################################################### -# Owners: cesarenrique@, ivanantonio@, edherivan@ -# Contact Method: Gchat/e-mail -# Created Date: # Purpose: Joins all Ads Sources from Data Transfer Service. ##################################################################### From dcd4112508d0013d4ac21be70ec3dd3cd3d33dae Mon Sep 17 00:00:00 2001 From: IVAN VALENZUELA UTRERA Date: Thu, 19 Dec 2024 23:18:27 +0000 Subject: [PATCH 2/2] Fix: edited daily goal field to be a plain value. Adjusted visualization parameter interpolation from step to linea in goal_vs_actual value LookML dashboard --- dashboards/goal_vs_actual.dashboard.lookml | 2 +- views/goals/campaigns_flat_goals.view.lkml | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/dashboards/goal_vs_actual.dashboard.lookml b/dashboards/goal_vs_actual.dashboard.lookml index 22a81c3..a15de6d 100644 --- a/dashboards/goal_vs_actual.dashboard.lookml +++ b/dashboards/goal_vs_actual.dashboard.lookml @@ -48,7 +48,7 @@ x_axis_scale: auto y_axis_combined: true show_null_points: true - interpolation: step + interpolation: linear y_axes: [{label: '', orientation: left, series: [{axisId: goals_campaigns.phase_goal, id: goals_campaigns.phase_goal, name: Actual Metric Value}], showLabels: true, showValues: true, maxValue: !!null '', minValue: 0, unpinAxis: false, tickDensity: default, diff --git a/views/goals/campaigns_flat_goals.view.lkml b/views/goals/campaigns_flat_goals.view.lkml index cd8bd32..02789e8 100644 --- a/views/goals/campaigns_flat_goals.view.lkml +++ b/views/goals/campaigns_flat_goals.view.lkml @@ -117,7 +117,7 @@ view: campaigns_flat_goals { measure: daily_goal { type: average label: "Daily Goal" - sql: ${equivalent_day_goal} + (RAND() - 0.5) * ${equivalent_day_goal} * 0.5;; + sql: ${equivalent_day_goal};; value_format_name: decimal_0 }