1
votes

When I do search in google's autocomplete I see correct address. Example:

Pavlichenko Street, 20b, Bila Tserkva, Kyiv Oblast, Ukraine

This address has place_id: EjtQYXZsaWNoZW5rbyBTdHJlZXQsIDIwYiwgQmlsYSBUc2Vya3ZhLCBLeWl2IE9ibGFzdCwgVWtyYWluZSIwEi4KFAoSCVcssl0EQtNAEeDmEfl02RgXEBQqFAoSCVGxb54DQtNAEbhYfU4LYvbk

I need to get a street number which is "20b". To do so I use Place Details API: https://maps.googleapis.com/maps/api/place/details/json?placeid=EjtQYXZsaWNoZW5rbyBTdHJlZXQsIDIwYiwgQmlsYSBUc2Vya3ZhLCBLeWl2IE9ibGFzdCwgVWtyYWluZSIwEi4KFAoSCVcssl0EQtNAEeDmEfl02RgXEBQqFAoSCVGxb54DQtNAEbhYfU4LYvbk&key=MY_KEY

And here what is in response:

      "address_components" : [
         {
            "long_name" : "20",
            "short_name" : "20",
            "types" : [ "street_number" ]
         },
         {
            "long_name" : "Pavlichenko Street",
            "short_name" : "Pavlichenko Street",
            "types" : [ "route" ]
         },
         {
            "long_name" : "Bila Tserkva",
            "short_name" : "Bila Tserkva",
            "types" : [ "locality", "political" ]
...

But "20" is actually different house, I need "20b". Same happens to all streets with letters. Is there way to solve this problem? Thank you

1
The autocomplete entry for that place is wrong, all the other details of the result don't have the "b". (fiddle). Seems like a data problem.geocodezip
I know exactly that 20b is correct because I live in this house. In Ukraine we have a lot of buildings with letters and all of them are displaying correctly in autocomplete but not in place details.Ivan Sadovsky
I wasn't saying the address is wrong, I was saying it is probably a data problem on Google's side.geocodezip

1 Answers

1
votes

The long place ID EjtQYXZsaWNoZW5rbyBTdHJlZXQsIDIwYiwgQmlsYSBUc2Vya3ZhLCBLeWl2IE9ibGFzdCwgVWtyYWluZSIwEi4KFAoSCVcssl0EQtNAEeDmEfl02RgXEBQqFAoSCVGxb54DQtNAEbhYfU4LYvbk indicates that this address is not present in Google database. They try to interpolate it to the best known position that matches your search.

Note that the existing in database addresses have a short place IDs, something like ChIJNSfioSOjpBIRSwaYW7O3LJY.

Your prediction has a following type

 "types":[
    "route","geocode"
  ]

So it looks like Google could resolve it to route level, but not to street address level.

I can suggest reporting a missing address to Google data team as explained in the documentation

https://support.google.com/maps/answer/3094088

I hope this addresses your doubt.