Inconsistent result - FindAddressByText

deals with geocoding and reverse geocoding in the context of PTV Geocoding&Places, PTV Geocoding&Places OSM and PTV xLocate 1 and 2
Post Reply
biro.daniel
Posts: 41
Joined: Tue Aug 23, 2016 8:08 am

Inconsistent result - FindAddressByText

Post by biro.daniel »

We have an issue in the xLocate app by finding address by text. (The address is „Valencia de Don Juan” in ES)
If „valencia de” is written in the Address field, the results contain the right location, but if „valencia de don” or „valencia de don juan” is added, the result will be Orihuela (city). This town totally differs from the target location, but there is a place in the town named Urbanización Castillo de Don Juan (city2).
If the post codes are added, the result is correct.
It seems when we query the result addresses the city2 field has larger weight.

How can we get the correct result?

Thank you in advance
BR
Daniel
Attachments
FindAddressByText_Valencia de.png
FindAddressByText_Valencia de don.png
FindAddressByText_Valencia de don juan.png
User avatar
bocajo
Posts: 45
Joined: Tue Mar 01, 2016 3:05 pm

Re: Inconsistent result - FindAddressByText

Post by bocajo »

Hi Daniel

The xLocate identifies Valencia as a state ;) The first input word in the Address field is tried as a country or state.
There are two possibilities to get Valencia de Don Juan:
1. Write the country before Valencia "E Valencia de Don Juan"
2. Switch off the parameter Region.CheckState=0.
You can switch off CheckState in the file conf\native-default.xml (you have to restart the xLocate).
Or per request:

Code: Select all

{
  "address": "Valencia de Don Juan",
  "country": "E",
  "options": [
    {
      "$type": "NamedSearchOption",
      "value": "false",
      "param": "Region.CheckState"
    }
  ],
  "sorting": [],
  "additionalFields": [],
  "callerContext": {
    "properties": [
      {
        "key": "CoordFormat",
        "value": "PTV_MERCATOR"
      },
      {
        "key": "Profile",
        "value": "default"
      }
    ]
  }
}
Hopefully this will help you
Regards
Jochen
Edit by Jcl, added code tag for readability
Jochen Anderer
Manager Engineer
PTV GROUP GERMANY
Post Reply