Filter on multiple ad groups

19 views
Skip to first unread message

Brad Melluish

unread,
Jan 27, 2025, 4:31:28 AM1/27/25
to Google Ads API and AdWords API Forum
Is there a way to filter on a list of ad group ids instead of just one (e.g., "WHERE ad_group.id = '12345'") in a GAQL query's WHERE clause?

Google Ads API Forum Advisor

unread,
Jan 27, 2025, 9:38:48 AM1/27/25
to d...@trafficbyintent.com, adwor...@googlegroups.com

Hi,

Thank you for contacting the Google Ads API support team.

In order to include multiple ad group Ids together as a filter, you can use ‘IN’ instead of ‘=’ operator. Please refer to the sample GAQL query:-

SELECT ad_group.id, ad_group.name FROM ad_group WHERE ad_group.id IN (<ad_group Id1>, <ad_group Id2>, <ad_group Id3>)

I hope this clarifies your issue. Feel free to reach out for any further concern/ queries.

This message is in relation to case "ref:!00D1U01174p.!5004Q02vGyaf:ref" (ADR-00285985)

Thanks,
 
Google Logo Google Ads API Team

Feedback
How was our support today?

rating1    rating2    rating3    rating4    rating5



Reply all
Reply to author
Forward
0 new messages