RE: segments is missing when query from shopping_performance_view

97 views
Skip to first unread message
Message has been deleted

Google Ads API Forum Advisor

unread,
Jan 14, 2022, 1:36:22 PM1/14/22
to adwor...@googlegroups.com
Hi Jia,

Thank you for your logs, I reproduced your issue. This is working as intended for the API, because I saw the same in a report in the UI's predefined reports for shopping by item Id there was returned a row that didn't have an item Id. Since the API can only be a conduit for the UI you may reach out to product support.

Regards,

Google Logo
Aryeh Baker
Google Ads API Team
 


ref:_00D1U1174p._5004Q2Uk0SW:ref

Google Ads API Forum Advisor

unread,
Jan 14, 2022, 1:39:53 PM1/14/22
to adwor...@googlegroups.com
Hi Jia, 

I had to remove your post because it contains logs. Here's a redacted version:

Hi, at first, I used this query,
 
SELECT segments.product_item_id, campaign.name FROM shopping_performance_view WHERE campaign.name = \'auto SSC for all\' AND segments.date DURING LAST_7_DAYS limit 2
 
And the result is,
 
 results {
  campaign {
    resource_name: "rn"
    name: "auto SSC for all"
  }
  shopping_performance_view {
    resource_name: "rn"
  }
}
results {
  campaign {
    resource_name: "rn"
    name: "auto SSC for all"
  }
  segments {
    product_item_id: "id"
  }
  shopping_performance_view {
    resource_name: "rn"
  }
}
field_mask {
  paths: "segments.product_item_id"
  paths: "campaign.name"
}
request_id: "PWHwmCtouQCfF4LQyE_3EQ"
 
Failure message: null
Status: Status{code=OK, description=null, cause=null}.
 
In the first result, “segments”is missing.
 
However, after I changed “product_item_id” to “product_title”in query, then I got the right result.
Response
--------
Body: results {
  campaign {
    resource_name: "rn"
    name: "auto SSC for all"
  }
  segments {
    product_title: "[\344\270\213\345\226\256\350\263\272200]\344\271\235\346\234\210\347\266\240\350\214\266\351\230\262\350\255\267\346\267\250\346\211\213\346\266\262(4000ml / 4\346\241\266 / \347\256\261)"
  }
  shopping_performance_view {
    resource_name: "rn"
  }
}
results {
  campaign {
    resource_name: "rn"
    name: "auto SSC for all"
  }
  segments {
    product_title: "[\344\270\213\345\226\256\350\263\272200]\345\210\251\350\255\267\346\250\202 \346\210\220\350\244\262\350\244\262\345\236\2134\346\254\241\345\260\277\351\207\217(m/l/ll)"
  }
  shopping_performance_view {
    resource_name: "rn"
  }
}
field_mask {
  paths: "segments.product_title"
  paths: "campaign.name"
}
request_id: "QhXorKrSy1ZYXkFKYcZLFQ"
 
Failure message: null
Status: Status{code=OK, description=null, cause=null}.
 
So is there something wrong?

Jia Hongchao

unread,
Jan 17, 2022, 12:11:55 AM1/17/22
to Google Ads API and AdWords API Forum
Thanks. And the reason is here. May this helps others

Google Ads API Forum Advisor

unread,
Jan 17, 2022, 11:30:14 AM1/17/22
to adwor...@googlegroups.com
Hi Jia,

Thank you for posting this for others to see! 
Reply all
Reply to author
Forward
0 new messages