Re: Placeholder Feed Item Report - AttributeValues

2017-08-02 Thread 'Shwetha Vastrad (AdWords API Team)' via AdWords API Forum
Hi Danny, 

Items of a list which are in JSON format will be returned as an array of 
strings. The actual raw returned values are escaped appropriately for the 
selected report download format 
.
 
You need to check if the CSV implementation supports embedded line breaks 
or newline characters inside text fields. 

Regards,
Shwetha, AdWords API Team.

-- 
-- 
=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~
Also find us on our blog and Google+:
https://googleadsdeveloper.blogspot.com/
https://plus.google.com/+GoogleAdsDevelopers/posts
=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~

You received this message because you are subscribed to the Google
Groups "AdWords API Forum" group.
To post to this group, send email to adwords-api@googlegroups.com
To unsubscribe from this group, send email to
adwords-api+unsubscr...@googlegroups.com
For more options, visit this group at
http://groups.google.com/group/adwords-api?hl=en
--- 
You received this message because you are subscribed to the Google Groups 
"AdWords API Forum" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to adwords-api+unsubscr...@googlegroups.com.
Visit this group at https://groups.google.com/group/adwords-api.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/adwords-api/b3837c1c-1fdf-4062-bfb6-3be1042ff354%40googlegroups.com.
For more options, visit https://groups.google.com/d/optout.


Re: Placeholder Feed Item Report - AttributeValues

2017-08-02 Thread Danny
I wonder if any \n in JSON data from API should be escaped then?

On Wednesday, 2 August 2017 10:46:14 UTC-7, Danny wrote:
>
> Ok nvm - I found the bug. Turns out the php functions *str_getcsv* and 
> *fgetcsv* will process line breaks \n within a field, hence it's 
> incorrectly splitting, and its possible to have line breaks within the JSON 
> data of *AttributeValues*.
>
> On Wednesday, 2 August 2017 09:55:40 UTC-7, Danny wrote:
>>
>> FYI - using v201609 
>>
>> On Wednesday, 2 August 2017 09:53:54 UTC-7, Danny wrote:
>>>
>>> Hi
>>>
>>> I'm running the Placeholder Feed Item Report with the following fields:
>>>
>>> $report_fields = ['PlaceholderType', 'FeedId', 'FeedItemId', 
>>> 'AttributeValues', 'CustomerDescriptiveName','ExternalCustomerId', 
>>> 'StartTime', 'EndTime', 'Status'];
>>> $segment_fields = ['AdGroupId', 'AdGroupName', 'AdGroupStatus', 
>>> 'CampaignId', 'CampaignName', 'CampaignStatus'];
>>>
>>> In total, there's 15 fields being queried. Once I execute* 
>>> downloadReport()* and *saveToFile()*, I noticed that the value of 
>>> *AttributeValues* returns a JSON that for some reason the data is split 
>>> into 2 columns. I'm running into errors as my header row is 15 fields, but 
>>> the data returned is 16 fields.
>>>
>>> Is this normal and if so, how does the API determine how/when should the 
>>> *AttributeValues* JSON be split into multiple columns?
>>>
>>

-- 
-- 
=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~
Also find us on our blog and Google+:
https://googleadsdeveloper.blogspot.com/
https://plus.google.com/+GoogleAdsDevelopers/posts
=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~

You received this message because you are subscribed to the Google
Groups "AdWords API Forum" group.
To post to this group, send email to adwords-api@googlegroups.com
To unsubscribe from this group, send email to
adwords-api+unsubscr...@googlegroups.com
For more options, visit this group at
http://groups.google.com/group/adwords-api?hl=en
--- 
You received this message because you are subscribed to the Google Groups 
"AdWords API Forum" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to adwords-api+unsubscr...@googlegroups.com.
Visit this group at https://groups.google.com/group/adwords-api.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/adwords-api/1ced1c8a-de33-488e-acda-8a99f81c6838%40googlegroups.com.
For more options, visit https://groups.google.com/d/optout.


Re: Placeholder Feed Item Report - AttributeValues

2017-08-02 Thread Danny
Ok nvm - I found the bug. Turns out the php functions *str_getcsv* and 
*fgetcsv* will process line breaks \n within a field, hence it's 
incorrectly splitting, and its possible to have line breaks within the JSON 
data of *AttributeValues*.

On Wednesday, 2 August 2017 09:55:40 UTC-7, Danny wrote:
>
> FYI - using v201609 
>
> On Wednesday, 2 August 2017 09:53:54 UTC-7, Danny wrote:
>>
>> Hi
>>
>> I'm running the Placeholder Feed Item Report with the following fields:
>>
>> $report_fields = ['PlaceholderType', 'FeedId', 'FeedItemId', 
>> 'AttributeValues', 'CustomerDescriptiveName','ExternalCustomerId', 
>> 'StartTime', 'EndTime', 'Status'];
>> $segment_fields = ['AdGroupId', 'AdGroupName', 'AdGroupStatus', 
>> 'CampaignId', 'CampaignName', 'CampaignStatus'];
>>
>> In total, there's 15 fields being queried. Once I execute* 
>> downloadReport()* and *saveToFile()*, I noticed that the value of 
>> *AttributeValues* returns a JSON that for some reason the data is split 
>> into 2 columns. I'm running into errors as my header row is 15 fields, but 
>> the data returned is 16 fields.
>>
>> Is this normal and if so, how does the API determine how/when should the 
>> *AttributeValues* JSON be split into multiple columns?
>>
>

-- 
-- 
=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~
Also find us on our blog and Google+:
https://googleadsdeveloper.blogspot.com/
https://plus.google.com/+GoogleAdsDevelopers/posts
=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~

You received this message because you are subscribed to the Google
Groups "AdWords API Forum" group.
To post to this group, send email to adwords-api@googlegroups.com
To unsubscribe from this group, send email to
adwords-api+unsubscr...@googlegroups.com
For more options, visit this group at
http://groups.google.com/group/adwords-api?hl=en
--- 
You received this message because you are subscribed to the Google Groups 
"AdWords API Forum" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to adwords-api+unsubscr...@googlegroups.com.
Visit this group at https://groups.google.com/group/adwords-api.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/adwords-api/7dffbf8f-7ea8-40e3-ad9d-1a5443e518c8%40googlegroups.com.
For more options, visit https://groups.google.com/d/optout.


Re: Placeholder Feed Item Report - AttributeValues

2017-08-02 Thread Danny
FYI - using v201609 

On Wednesday, 2 August 2017 09:53:54 UTC-7, Danny wrote:
>
> Hi
>
> I'm running the Placeholder Feed Item Report with the following fields:
>
> $report_fields = ['PlaceholderType', 'FeedId', 'FeedItemId', 
> 'AttributeValues', 'CustomerDescriptiveName','ExternalCustomerId', 
> 'StartTime', 'EndTime', 'Status'];
> $segment_fields = ['AdGroupId', 'AdGroupName', 'AdGroupStatus', 
> 'CampaignId', 'CampaignName', 'CampaignStatus'];
>
> In total, there's 15 fields being queried. Once I execute* 
> downloadReport()* and *saveToFile()*, I noticed that the value of 
> *AttributeValues* returns a JSON that for some reason the data is split 
> into 2 columns. I'm running into errors as my header row is 15 fields, but 
> the data returned is 16 fields.
>
> Is this normal and if so, how does the API determine how/when should the 
> *AttributeValues* JSON be split into multiple columns?
>

-- 
-- 
=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~
Also find us on our blog and Google+:
https://googleadsdeveloper.blogspot.com/
https://plus.google.com/+GoogleAdsDevelopers/posts
=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~

You received this message because you are subscribed to the Google
Groups "AdWords API Forum" group.
To post to this group, send email to adwords-api@googlegroups.com
To unsubscribe from this group, send email to
adwords-api+unsubscr...@googlegroups.com
For more options, visit this group at
http://groups.google.com/group/adwords-api?hl=en
--- 
You received this message because you are subscribed to the Google Groups 
"AdWords API Forum" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to adwords-api+unsubscr...@googlegroups.com.
Visit this group at https://groups.google.com/group/adwords-api.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/adwords-api/b7ae3cb4-49c1-434c-9b8e-a4628118710c%40googlegroups.com.
For more options, visit https://groups.google.com/d/optout.


Placeholder Feed Item Report - AttributeValues

2017-08-02 Thread Danny
Hi

I'm running the Placeholder Feed Item Report with the following fields:

$report_fields = ['PlaceholderType', 'FeedId', 'FeedItemId', 
'AttributeValues', 'CustomerDescriptiveName','ExternalCustomerId', 
'StartTime', 'EndTime', 'Status'];
$segment_fields = ['AdGroupId', 'AdGroupName', 'AdGroupStatus', 
'CampaignId', 'CampaignName', 'CampaignStatus'];

In total, there's 15 fields being queried. Once I execute* downloadReport()* 
and *saveToFile()*, I noticed that the value of *AttributeValues* returns a 
JSON that for some reason the data is split into 2 columns. I'm running 
into errors as my header row is 15 fields, but the data returned is 16 
fields.

Is this normal and if so, how does the API determine how/when should the 
*AttributeValues* JSON be split into multiple columns?

-- 
-- 
=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~
Also find us on our blog and Google+:
https://googleadsdeveloper.blogspot.com/
https://plus.google.com/+GoogleAdsDevelopers/posts
=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~

You received this message because you are subscribed to the Google
Groups "AdWords API Forum" group.
To post to this group, send email to adwords-api@googlegroups.com
To unsubscribe from this group, send email to
adwords-api+unsubscr...@googlegroups.com
For more options, visit this group at
http://groups.google.com/group/adwords-api?hl=en
--- 
You received this message because you are subscribed to the Google Groups 
"AdWords API Forum" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to adwords-api+unsubscr...@googlegroups.com.
Visit this group at https://groups.google.com/group/adwords-api.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/adwords-api/9d6bfc56-5297-4759-bfd6-e9d7eb0e1b6d%40googlegroups.com.
For more options, visit https://groups.google.com/d/optout.