How to deal with "--" values

33 views
Skip to first unread message

Zweitze

unread,
Oct 26, 2016, 11:24:56 AM10/26/16
to AdWords API Forum

Hi,

In v201603 we got a change in reporting, string fields with NULL values are consistently reported as "--". I always wondered how to work with this, since "--" is a perfectly valid string value. Yes, you can create a campaign named "--", and a group too. (Google: just check campaign 688822988, and group 386353)

But maybe those fields can never be NULL, so my first question is: which fields are nullable and which fields are not? Ideally I would like to see the reporting documentation extended, telling for every field whether it is nullable or not.

Recently certain fields are reported as NULL which didn't happen before - especially Path1 and Path2 of extended text ads. And now it gets tricky, because "--" is actually a valid value for these fields... Check out the attached screenshot! (Google: you can find this ad in the group mentioned earlier).

But this particular ad gives me a problem, when I request an ad performance report, it both Path1 and Path2 report value "--". One of them should be interpreted as "--", the other as NULL. How can I do that?

So I have two questions:
1. Can the reporting documentation be updated, stating which fields can be NULL?
2. How does one distinguish NULL from the text "--"

Thanks in advance!
Capture.PNG

Shwetha Vastrad (AdWords API Team)

unread,
Oct 26, 2016, 12:30:46 PM10/26/16
to AdWords API Forum
Hi Zweitze,

We are working on making the reporting of null values for String fields more consistent. The reference document for each object state if a field can be null or not (AdGroup.name for example). The Path1 and Path2 fields for an Expanded Text ads are optional at the moment. So, null values for these fields would be returned as "--" in reports which would be difficult to distinguish from Path fields with "--" as the text. There is another thread on the forum where a similar discussion is going on. You could provide your inputs on that thread as well. I'll pass this along to the team and keep you updated. 

Regards,
Shwetha, AdWords API Team.

Zweitze

unread,
Oct 27, 2016, 7:22:26 AM10/27/16
to AdWords API Forum
Thanks, I will add my thoughts on the other thread.

I am not sure what you mean by " The reference document for each object state if a field can be null or not (AdGroup.name for example)". This is not about API objects, this is about report fields. Most report fields do not have a counterpart in API objects. Just think of ClickType or Conversions. Can they be null? I can imagine Conversions being NULL in accounts where no conversions are defined. But it's hard to test, you have to create a new account with credit card info etc., then direct traffic to it. It's quite an effort.

What makes this issue worse is that reporting is updated more often than the regular AdWords API, and the time given to us developers is much smaller. (For instance, this breaking change gives developers just 40 days to develop the necessary changes. In those 40 days the development efforts cannot be fully tested since the announced change cannot be tested in advance. So we have to depend on all available information.)

Summary: I want nullable documentation for every report field. Just like "Type", "Display Name", "Behavior" etc., another attribute "Can be NULL" which just says True or False - and maybe some information in which circumstances this field will be NULL.

Can you pass this request?

Shwetha Vastrad (AdWords API Team)

unread,
Oct 27, 2016, 10:27:19 AM10/27/16
to AdWords API Forum
Hi Zweitze,

Thanks for providing such a detailed explanation. Some attributes of objects are required and cannot be null, CampaignName, AdGroupName etc. So if the respective column in the report contains "--", you can consider that as an actual value and not equivalent to null. I understand it would be difficult to infer whether a report field, especially one which is a metric, can be null. I'll pass this along to the team. I'll keep you notified about any updates. 
Reply all
Reply to author
Forward
0 new messages