Python Google Ads: Escape user input for GAQL queries

2021-08-11 Thread Alex Mohr
What's the best way to escape user input for use in GAQL queries when searching with the GoogleAdsService with the Python client library? For example: search = "Something from user input" query = f"SELECT campaign.id FROM campaign WHERE campaign.name LIKE '%{search}%'" google_ads_service.search

Re: Python Google Ads: Escape user input for GAQL queries

2021-08-13 Thread Alex Mohr
This seems like an issue with all of the client libraries. How do you build a GAQL query with untrusted user input? is there a query builder interface that sanitizes input? On Thursday, August 12, 2021 at 11:51:47 AM UTC-7 adsapi wrote: > Hi Alex, > > You can get support for the Python Client L