impression count is increasing in the query

42 views
Skip to first unread message

Anurag

unread,
Sep 19, 2022, 9:03:06 AM9/19/22
to Google Ads API and AdWords API Forum
I am running a query to get the impressions count based on city using "SELECT segments.geo_target_city segments.date, campaign.id, campaign.name, geographic_view.country_criterion_id FROM geographic_view WHERE metrics.impressions > 0 AND segments.date BETWEEN '2021-07-08' AND '2022-09-16'

but the count is around 22k without adding segments.geo_target_city but increases to around 45k with adding segments.geo_target_city.

whats wrong in the query?

Thanks

Google Ads API Forum Advisor

unread,
Sep 19, 2022, 9:57:08 AM9/19/22
to adwor...@googlegroups.com
Hi Anurag,

Thank you for reaching out to Google Ads API support with your question. Adding a segment to your query divides rows so you potentially get more rows. An example in your query is you use segments.date,  this divides your row with all dates combined from 7/8 to 9/6 into a separate row for each day. The same is true when you segment by city, each city potentially gets its own row.

When it comes to unexpected report results,  this support channel can only support the discrepancies between API reports and UI reports. For any other issues with unexpected report results I suggest you reach out to our product support team for further assistance. The Ads API can only be a conduit to the Ads product as expressed in the Ads UI.

In light of the above, to assist you further, could you send us a 'DEBUG' log level request and response log of raw API communications of an API report that differs from a UI report? Note that the UI report needs to match the resource level off the API report (here's a list of Predefined Reports), have the same fields in 'row columns' that the API report has in segmenting columns and the filters have to be the same. Also, both reports have to be pulled in the same time frame due to issues with data freshness.

The request and response appears similar to the JSON Mappings in our REST documentation with additional headers and information such as request Id. Here are logging instructions for our Java.NETPHPPythonRuby and Perl Ads API Client Libraries.

If you are using our REST interface then the full multi line curl command line is a request log and adding curl command line option '-i' will also generate a response log.

You may send the requested information via "Reply to author" or via googleadsa...@google.com with a link to this forum post added to the new thread.

Regards,

Google Logo
Aryeh
Google Ads API Team
 


ref:_00D1U1174p._5004Q2eQPRe:ref
Reply all
Reply to author
Forward
0 new messages