Hi guys! I am trying to use custom GAQL Query in g...
# ask-community-for-troubleshooting
m
Hi guys! I am trying to use custom GAQL Query in google ads source, but I don't get any update on this cutom report in the destination. How can I manage to correct it?
āœ… 1
message has been deleted
m
@Matheus Guinezi can you test the example query? Would that land data in your destination?
m
I've tested it, but it didn't land in the destination
m
Here are other examples:
Copy code
"custom_queries": [
    {
      "query": "SELECT campaign.accessible_bidding_strategy, segments.ad_destination_type, campaign.start_date, campaign.end_date FROM campaign",
      "primary_key": null,
      "cursor_field": "campaign.start_date",
      "table_name": "happytable"
    },
    {
      "query": "SELECT segments.ad_destination_type, segments.ad_network_type, segments.day_of_week, customer.auto_tagging_enabled, customer.id, metrics.conversions, campaign.start_date FROM campaign",
      "primary_key": "customer.id",
      "cursor_field": null,
      "table_name": "unhappytable"
    },
    {
      "query": "SELECT ad_group.targeting_setting.target_restrictions FROM ad_group",
      "primary_key": "customer.id",
      "cursor_field": null,
      "table_name": "ad_group_custom"
    }
  ]
Iā€™d used the first and was able to get records
Copy code
2022-03-03 00:51:09 INFO i.a.w.DefaultReplicationWorker(lambda$getReplicationRunnable$5):304 - Total records read: 442
In my case I changed the name to
custom_gaql_query
šŸ™‚
If you run the query in the GAQL editor it works?
m
That's great! Problably is something in my setup. Did you test it with source code instead of the UI? I saw you're using config.json template for custom_queries
I am testing happytable example too, adding it from UI, but the table doesn't land in my destination (s3)
m
I used the UI šŸ˜„ Just posted as the config because Iā€™d saved in my notes
m
I've got it now! I needed to refresh schema in the connection to recognize my custom query. Thanks a lot @Marcos Marx (Airbyte)
šŸ˜… 1