"conversion action" report

325 views
Skip to first unread message

EladB

unread,
Jul 5, 2021, 12:33:15 PM7/5/21
to AdWords API and Google Ads API Forum
Hi

I was trying to call the suggested report API (based on this sample), but I get an error message:

    var query = "SELECT conversion_action.firebase_settings.event_name, conversion_action.status, conversion_action.resource_name FROM conversion_action DURING LAST_30_DAYS";
    var report = AdWordsApp.report(query, {apiVersion: reportVersion});
    var rows = report.rows();

Exception: Call to GoogleAdsService.Search failed: Error in query: unexpected input DURING. (file Code.gs, line 65)

If I call it without the DURING clause I get an empty result set.

How can I prolong the date range if DURING is not allowed?

Google Ads API Forum Advisor

unread,
Jul 6, 2021, 2:59:11 AM7/6/21
to adwor...@googlegroups.com
Hi,

It appears that your concern is related to the Google Ads Scripts. That said, you may reach out to their support team via their forum channel instead. I hope this helps.

Best regards,

Google Logo
Peter Laurence Napa Oliquino
Google Ads API Team
 


ref:_00D1U1174p._5004Q2JYl0i:ref

Pete Lavetsky (AdWords API Guru)

unread,
Jul 6, 2021, 11:16:15 AM7/6/21
to AdWords API and Google Ads API Forum
Hey Elad,

You can use the Query Builder tool to validate your query:

https://developers.google.com/google-ads/api/fields/v8/conversion_action_query_builder

Pete

Elad Ben-David

unread,
Jul 6, 2021, 11:20:58 AM7/6/21
to pete.l...@gmail.com, AdWords API and Google Ads API Forum
Thanks,

I actually created it with the tool, so it's supposed to be syntactically correct.

However, I don't get the logic.
If I see in the GAds UI view that there are some conversion actions, but the query returns an empty result set - then how can I bridge that gap?


Intuitively I could have expanded the date range, but syntactically it's not applicable.

--
--
=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~
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...@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 a topic in the Google Groups "AdWords API and Google Ads API Forum" group.
To unsubscribe from this topic, visit https://groups.google.com/d/topic/adwords-api/qPCu3qosDS0/unsubscribe.
To unsubscribe from this group and all its topics, send an email to adwords-api...@googlegroups.com.
To view this discussion on the web visit https://groups.google.com/d/msgid/adwords-api/45679429-2532-465a-b343-35c5fd4a92f0n%40googlegroups.com.

Pete Lavetsky (AdWords API Guru)

unread,
Jul 6, 2021, 11:26:30 AM7/6/21
to AdWords API and Google Ads API Forum
Elad,

You haven't given the query any "where" criteria for DURING LAST_30 days

This is how the Query Builder builds out your query:

SELECT conversion_action.firebase_settings.event_name, conversion_action.status, conversion_action.resource_name FROM conversion_action WHERE metrics.conversion_last_conversion_date DURING LAST_30_DAYS

Pete

Elad Ben-David

unread,
Jul 6, 2021, 11:44:07 AM7/6/21
to pete.l...@gmail.com, AdWords API and Google Ads API Forum
Thanks, I will give it a try.

WDYT about this comment in SOF?

Elad Ben-David

unread,
Jul 7, 2021, 9:24:14 AM7/7/21
to pete.l...@gmail.com, AdWords API and Google Ads API Forum
Thanks, I ran the query and got no result:
Even though the UI shows there has been an action in the last 30 days.


BTW, 
I prolonged the date range and have gotten only one result row with "undefined" values.

    var query = "SELECT conversion_action.firebase_settings.event_name, conversion_action.status, conversion_action.resource_name FROM conversion_action WHERE metrics.conversion_last_conversion_date > '2020-01-01'";



Google Ads API Forum Advisor

unread,
Jul 12, 2021, 1:52:51 AM7/12/21
to adwor...@googlegroups.com, pete.l...@gmail.com
Hi everyone,

Since this appears to be a Scripts issue, you may continue discussions with the Scripts Support team instead, via this channel, for further assistance.

As an additional information, for conversions that are not appearing in the reports, you may take note of the impression date of the click, as the date filter and as discussed here, and also the Include in Conversions column in the Google Ads UI view.
Reply all
Reply to author
Forward
0 new messages