Hi,

how can I assign a list to predicates values in an AWQL query string?

this code works:
query = (adwords.ServiceQueryBuilder()
.Select('Id', 'Status')
.Where('BaseCampaignId').In("1435278870", "2345678901", "3456789012")
.Build())


this code works too:
query = (adwords.ServiceQueryBuilder()
.Select('Id', 'Status')
.Where('BaseCampaignId').In(1435278870, 2345678901, 3456789012)
.Build())

and even this code works:
campagin_ids = [1435278870, 2345678901, 3456789012]           
query = (adwords.ServiceQueryBuilder()
.Select('Id', 'Status')
.Where('BaseCampaignId').In(campaign_ids[0],campaign_ids[1], 
campaign_ids[2])         
.Build())                      

unfortunately, this code throws an error:
campagin_ids = [1435278870, 2345678901, 3456789012]           
query = (adwords.ServiceQueryBuilder()
.Select('Id', 'Status')
.Where('BaseCampaignId').In(campaign_ids)         
.Build())

> googleads.errors.GoogleAdsServerFault: 
[QueryError{reason=INVALID_WHERE_CLAUSE, message=}]


So, how do I have to handle the list to make it work properly as predicates 
values (without having to assign the values manually)? 

Best regards
Matthias


-- 
-- 
=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~
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 adwords-api@googlegroups.com
To unsubscribe from this group, send email to
adwords-api+unsubscr...@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+unsubscr...@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/77b48ee8-c752-42cb-acce-886baaaf83b6%40googlegroups.com.
For more options, visit https://groups.google.com/d/optout.
  • AWQL - How to prope... Matthias Baader

Reply via email to