Google Ads Scripts AWQL "CONTAINS_ANY" operator doesn't work
I'm trying to extract Search queries by certain rules and I need to get Queries that contain one of the given strings:
" WHERE " + " Impressions > " + IMPRESSIONS_THRESHOLD + " AND AverageCpc > " + AVERAGE_CPC_THRESHOLD + " AND Query CONTAINS_ANY ['for sale in', 'buy'] " + " DURING YESTERDAY ");
But I'm getting error message (tryed different variations):
One of the conditions in the query is invalid. (file Code.gs, line 19)
Although it seems like I do everything according to Formal Grammar:
String -> StringSingleQ | StringDoubleQ StringSingleQ -> '(char)' StringDoubleQ -> "(char)" StringList -> [ String (, String)* ]
If I do just 1 string it works fine:
" WHERE " + " Impressions > " + IMPRESSIONS_THRESHOLD + " AND AverageCpc > " + AVERAGE_CPC_THRESHOLD + " AND Query CONTAINS 'for sale in' " + " DURING YESTERDAY ");