Skip to content

Instantly share code, notes, and snippets.

@graham-thomson
Created April 27, 2018 13:37
Show Gist options
  • Save graham-thomson/be5a80315db4109d4875fc22372c4be9 to your computer and use it in GitHub Desktop.
Save graham-thomson/be5a80315db4109d4875fc22372c4be9 to your computer and use it in GitHub Desktop.
SELECT
event_time,
--user_id,
advertiser_id,
campaign_id,
ad_id,
rendering_id,
creative_version,
site_id_dcm,
placement_id,
country_code,
state_region,
browser_platform_id,
browser_platform_version,
operating_system_id,
u_value,
activity_id,
tran_value,
other_data,
ord_value,
interaction_time,
conversion_id,
segment_value_1,
floodlight_configuration,
event_type,
event_sub_type,
dbm_auction_id,
dbm_request_time,
dbm_advertiser_id,
dbm_insertion_order_id,
dbm_line_item_id,
dbm_creative_id,
dbm_bid_price_usd,
dbm_bid_price_partner_currency,
dbm_bid_price_advertiser_currency,
dbm_url,
dbm_site_id,
dbm_language,
dbm_adx_page_categories,
dbm_matching_targeted_keywords,
dbm_exchange_id,
dbm_attributed_inventory_source_external_id,
dbm_attributed_inventory_source_is_public,
dbm_ad_position,
dbm_country_code,
dbm_designated_market_area_dma_id,
dbm_zip_postal_code,
dbm_state_region_id,
dbm_city_id,
dbm_operating_system_id,
dbm_browser_platform_id,
dbm_browser_timezone_offset_minutes,
dbm_net_speed,
dbm_matching_targeted_segments,
dbm_isp_id,
dbm_device_type,
dbm_mobile_make_id,
dbm_mobile_model_id,
--partner1_id,
--partner2_id,
total_conversions,
total_revenue,
dbm_media_cost_usd,
dbm_media_cost_partner_currency,
dbm_media_cost_advertiser_currency,
dbm_revenue_usd,
dbm_revenue_partner_currency,
dbm_revenue_advertiser_currency,
dbm_total_media_cost_usd,
dbm_total_media_cost_partner_currency,
dbm_total_media_cost_advertiser_currency,
dbm_cpm_fee_1_usd,
dbm_cpm_fee_1_partner_currency,
dbm_cpm_fee_1_advertiser_currency,
dbm_cpm_fee_2_usd,
dbm_cpm_fee_2_partner_currency,
dbm_cpm_fee_2_advertiser_currency,
dbm_cpm_fee_3_usd,
dbm_cpm_fee_3_partner_currency,
dbm_cpm_fee_3_advertiser_currency,
dbm_cpm_fee_4_usd,
dbm_cpm_fee_4_partner_currency,
dbm_cpm_fee_4_advertiser_currency,
dbm_cpm_fee_5_usd,
dbm_cpm_fee_5_partner_currency,
dbm_cpm_fee_5_advertiser_currency,
dbm_media_fee_1_usd,
dbm_media_fee_1_partner_currency,
dbm_media_fee_1_advertiser_currency,
dbm_media_fee_2_usd,
dbm_media_fee_2_partner_currency,
dbm_media_fee_2_advertiser_currency,
dbm_media_fee_3_usd,
dbm_media_fee_3_partner_currency,
dbm_media_fee_3_advertiser_currency,
dbm_media_fee_4_usd,
dbm_media_fee_4_partner_currency,
dbm_media_fee_4_advertiser_currency,
dbm_media_fee_5_usd,
dbm_media_fee_5_partner_currency,
dbm_media_fee_5_advertiser_currency,
dbm_data_fees_usd,
dbm_data_fees_partner_currency,
dbm_data_fees_advertiser_currency,
dbm_billable_cost_usd,
dbm_billable_cost_partner_currency,
dbm_billable_cost_advertiser_currency,
country,
dt
FROM
doubleclick.impressions
;
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment