Hi,

We've identified the source of the inconsistency and will look into fixing 
the *LocationCriterionService* in a future version so that it returns 
unique canonical names. We won't be changing the behavior in released 
versions (v201406 and v201409) since that would be a behavior change that 
could break users.

In the meantime, you can use the CSV file if you want to look up by unique 
*canonicalName*. The IDs returned will be valid for use in creating 
*Location* criteria, even though the canonical names won't match those 
returned by *LocationCriterionService*.

Thanks,
Josh, AdWords API Team

On Monday, July 28, 2014 1:02:01 PM UTC-4, Josh Radcliff (AdWords API Team) 
wrote:
>
> Hi,
>
> I'm looking into this and will post an update as soon as I have more 
> information.
>
> Thanks,
> Josh, AdWords API Team
>
> On Monday, July 28, 2014 4:54:31 AM UTC-4, Dzmitry Zahusta wrote:
>>
>> Hi!
>>
>> I'm trying to get location names using the following code:
>>
>>         Selector selector = new SelectorBuilder()
>>         .fields(
>>             "Id",
>>             "LocationName",
>>             "DisplayType",
>>             "CanonicalName",
>>             "TargetingStatus")
>>         .in("LocationName", locationName)
>>
>>         .equals("Locale", "en")
>>
>>         .build();
>>
>>
>>         // Make the get request.
>>         LocationCriterion[] locationCriteria = locationCriterionService.
>> get(selector);
>>
>> And comparing results that I get in "CanonicalName" field - it's 
>> absolutely different from that I get using 
>> https://developers.google.com/adwords/api/docs/appendix/geotargeting 
>> page.
>>
>> Factually "CanonicalName" that I got in runtime is equal to locationName 
>> while on web page it looks like this (for Paris):
>>
>> *Paris,Ontario,Canada*
>> *Paris,Paris,Ile-de-France,France*
>> *Paris,Arkansas,United States*
>> *Paris,Idaho,United States*
>> *Paris,Illinois,United States*
>> *New Paris,Indiana,United States*
>> *Paris,Kentucky,United States*
>> *Paris,Maine,United States*
>> *South Paris,Maine,United State*
>>
>> And for the runtime request:
>>             <rval>
>>                 <location>
>>                     <id>1018992</id>
>>                     <Criterion.Type>Location</Criterion.Type>
>>                     <locationName>Paris</locationName>
>>                     <displayType>City</displayType>
>>                     <targetingStatus>ACTIVE</targetingStatus>
>>                      .....
>>                 </location>
>>             *    <canonicalName>Paris</canonicalName>*
>>                 <reach>13000</reach>
>>                 <locale>en</locale>
>>                 <searchTerm>Paris</searchTerm>
>>             </rval>
>>
>> What is wrong with LocationCriterionService? Why it returns incorrect 
>> values for *canonicalName?*
>>
>>

-- 
-- 
=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~
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 [email protected]
To unsubscribe from this group, send email to
[email protected]
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 [email protected].
Visit this group at http://groups.google.com/group/adwords-api.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/adwords-api/987b88c7-bcd7-42cc-94ce-e24629203dbe%40googlegroups.com.
For more options, visit https://groups.google.com/d/optout.

Reply via email to