Problem with CAMPAIGN_LOCATION_TARGET_REPORT

26 views
Skip to first unread message

Taras

unread,
Jan 15, 2019, 10:38:59 AM1/15/19
to AdWords API and Google Ads API Forum
I download data from CAMPAIGN_LOCATION_TARGET_REPORT via API v201809.
At the same time I download data from CAMPAIGN_PERFORMANCE_REPORT.

I use fileds: Cost, Impressions, Clicks.

The SUM in total of this fields (Cost, Impressions, Clicks) has some differens beetween two repots: CAMPAIGN_LOCATION_TARGET_REPORT, CAMPAIGN_PERFORMANCE_REPORT

Numbers from CAMPAIGN_PERFORMANCE_REPORT are the same like in Web-inferface - everything is OK.

But number from CAMPAIGN_LOCATION_TARGET_REPORT is little bit bigger. I don't understand why?

Can you download this two reports for account 478-325-6348 and dates 2018-12-01 - 2018-12-31 all campaigns (no restrictions) and see the difference.

My excpectations: SUMs should be the same. But I didnt get.

The code is below:
1)
fields = ['CampaignId', 'CampaignName', 'CampaignStatus', 'Id', 'Date', 'Interactions', 'InteractionTypes', 'Clicks', 'Impressions', 'Cost','Engagements', 'VideoViews', 'ViewThroughConversions', 'AveragePosition', 'CampaignStatus']
include_zero_impressions = True
report_query = (adwords.ReportQueryBuilder()
                  .Select(*fields)
                  .From('CAMPAIGN_LOCATION_TARGET_REPORT')
                  .Where('CampaignStatus').In('ENABLED', 'PAUSED')
                  .During(start_date.strftime('%Y%m%d') + ',' + end_date.strftime('%Y%m%d'))
                  .Build())

    res = report_downloader.DownloadReportAsStringWithAwql(
                report_query, 'CSV', skip_report_header=True,
                skip_column_header=False, skip_report_summary=True,
                include_zero_impressions=include_zero_impressions)
    import pandas as pd
    from io import StringIO
    adwords_df = pd.read_csv(StringIO(res))

2)
report = 'CAMPAIGN_PERFORMANCE_REPORT'
fields_query = ['Date', 'AccountDescriptiveName', 'AdvertisingChannelType', 'AdvertisingChannelSubType',  'AdNetworkType1', 'CampaignId', 'CampaignName', 'Impressions', 'Clicks', 'Cost', 'AccountCurrencyCode']

    report_query = (adwords.ReportQueryBuilder()
                  .Select(*fields_query)
                  .From(report)
                  .Where('CampaignStatus').In('ENABLED', 'PAUSED')
                  .During(start_date.strftime('%Y%m%d') + ', ' + end_date.strftime('%Y%m%d'))
                  .Build())

    res = report_downloader.DownloadReportAsStringWithAwql(
                report_query, 'CSV', skip_report_header=True,
                skip_column_header=False, skip_report_summary=True,
                include_zero_impressions=False,
    )
    
    adwords_df = pd.read_csv(StringIO(res))

googleadsapi...@google.com

unread,
Jan 18, 2019, 2:22:36 PM1/18/19
to t4r7...@gmail.com, AdWords API and Google Ads API Forum
Hello,

My apologies in my delay in getting back to you. We had a high priority issue that came in that was affecting a number of users, and you're question takes a lot of research and diving into the data to figure out. On the surface, it doesn't look easy. Your issue is my next task. I'll get back to you soon.

Cheers,
Nadine Sundquist, AdWords API Team
=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~
Also find us on our blog and discussion group:
    http://googleadsdeveloper.blogspot.com/search/label/adwords_api
    https://developers.google.com/adwords/api/community/
=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~

--
--
=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~
Also find us on our blog:
https://googleadsdeveloper.blogspot.com/
=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~
 
You received this message because you are subscribed to the Google
Groups "AdWords API and Google Ads API Forum" group.
To post to this group, send email to adwor...@googlegroups.com
To unsubscribe from this group, send email to
adwords-api+unsubscribe@googlegroups.com
For more options, visit this group at
http://groups.google.com/group/adwords-api?hl=en
---
You received this message because you are subscribed to the Google Groups "AdWords API and Google Ads API Forum" group.
To unsubscribe from this group and stop receiving emails from it, send an email to adwords-api+unsubscribe@googlegroups.com.
Visit this group at https://groups.google.com/group/adwords-api.
To view this discussion on the web visit https://groups.google.com/d/msgid/adwords-api/94044857-61d3-45f9-a8e6-32ef4e0f11c8%40googlegroups.com.
For more options, visit https://groups.google.com/d/optout.

googleadsapi...@google.com

unread,
Jan 18, 2019, 4:16:16 PM1/18/19
to t4r7...@gmail.com, AdWords API and Google Ads API Forum
Greetings!

I finally tracked it down. So, if you scroll to the bottom in the UI on the Locations page, you will see a sum for 'Locations', and you'll see a sum for 'Other Locations'. If you add up those two sums, it will equal the total in the API. I have no idea what this account total is coming from in the UI, but it does not equal the sum of those two rows. What's really cool is that the API breaks down 'Other Locations' into the specific locations. That's why you end up with extra rows in the API that you don't see in the UI. I'll send you the exact data privately. I just wanted to make sure if someone bumped into this, they would know what to do. This took me awhile to figure out because I made the assumption that the Total for everything in the UI was the sum of all the rows. It isn't. I'm not an expert on the UI, but perhaps there's another use for that row that I'm not aware of at the moment.

Regards,
Nadine, AdWords API Team
=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~
Also find us on our blog and discussion group:
    http://googleadsdeveloper.blogspot.com/search/label/adwords_api
    https://developers.google.com/adwords/api/community/
=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~

Reply all
Reply to author
Forward
0 new messages