Geocoding Servers

Provides access to popular web-based geocoders.  Some geocoding servers may require licensing or a key for access.  Geocoders built into the dataport include Bing, Google, Here, MapBox, MapQuest, OpenCage, and Yandex, with geocoding, reverse geocoding, search by attribute filter, search within radius, and search within bounding rectangle for many geocoders.   We can use web-based geocoders in Manifold by creating a new data source of type Web Server: geocodeserver using the File - Create - New Data Source command.  

 

Geocoders are used for street address geocoding as discussed in the Street Address Geocoding topic.   See also the Example: Street Address Geocoding topic.

 

Connecting to a geocoding server:

 

  1. Choose File - Create - New Data Source in the main menu, or right-click in the Project pane and choose New Data Source.

  2. In the dropdown menu choose More... to launch the New Data Source dialog.

  3. Enter a memorable name for the data source, if desired, in the Name box.

  4. Choose Web Server: geocodeserver in the Type box.

  5. Choose the desired geocoder in the box below the Type box.

  6. Provide an API key if required by the geocoder.

  7. Default settings for other options will usually work for most geocoders.   Press Create Data Source.

  8. A new geocoding data source appears in the project.

 

New Data Source Dialog and Controls

In the main menu, choose File - Create - New Data Source.   The dropdown menu provides a list of favorites to choose from as well as a More... option.  

 

 

Choose More... to launch the New Data Source dialog.   Choose Web Server: geocodeserver in the Type box.

 

 

Name

Name for the new data source, "Data Source" by default.  Specify a more memorable name as desired.  If we forget the origin of a data source we can hover the mouse over the data source name in the Project pane and a tool tip will provide connection information.

Type

Choose Web Server: geocodeserver in the Type box to connect to a geocoding server over the web.

 

In the box below the Type box, choose the geocoder desired.

Source

A connection string to the web-based geocoder.  This may be a simple URL, or a very lengthy, complex  URL/connection string that embeds parameters such as keys that grant access or other parameters.  The connection string can also be entered using the Web Login dialog launched by the [...] browse button.

 Browse button

Click to launch the Web Login dialog, to allow use of a login and password plus use of a proxy server if desired.   The Web Login dialog is also handy for providing a Test button that can be used to test the connection.

Open as read-only

Open the data source read-only.  Has no effect with geocoding servers since they are read-only in any event.

Cache data

Cache data downloaded from the server while the project is open.  Provides better interactive performance and greater flexibility with read-only data sources.  Checked by default.  Leave this box checked.

Save cached data between sessions

Save the cached data for the next time this project is opened, within the .map project itself in a Cache sub-folder in the System Data hierarchy.   Caution: checking this box can result in very large .map files when the results of browsing very large data from web servers are all saved.  However, having such data cached in the .map is handy for offline browsing of the project.

API key

Enter the API key for the geocoder account that is to be used, if the geocoder requires an API key for access.

Create Data Source

Create the new data source in the project pane and close the dialog.

Edit Query

Launch the Command Window loaded with a query that creates the data source using the given settings.  A great way to learn how to use SQL to create data sources.

Cancel

 Exit the dialog without doing anything.

 

 

 Pressing the browse button next to the Source box launches the Web Login dialog, to specify a server and connection characteristics.

 

 

(connection strings)

A list of connection strings that can be used with this geocoding server to provide various services, such as geocoding or reverse geocoding.  Click a row to choose that row.

Use login and password

Check this box for servers that require logging in with a login name and a password, providing the required name and password in the Login and Password boxes.

Use proxy server

Check this box when connecting through a proxy server.   The Proxy, Login, and Password boxes allow specifying the connection string to the proxy server as well as the login name and password required to use the proxy server.

User agent

Identifies what application (Manifold) is asking for a connection.  Some web servers want to know what client software is connecting, for compatibility or for business reasons.  The default string optimizes compatibility (Mozilla is very generic) while also identifying Manifold Release 9 as the client.  Users can adjust the string as necessary to comply with any special server requirements.

API key

Provide a key that authorizes use of an API when connecting to a geocoding server  that requires such a key.    This option is disabled for server dataports that do not use it.

Application key

A secondary application key or authentication code for those servers that may require it.    This option is disabled for server dataports that do not use it.

Timeout

Specify a time in milliseconds to wait for connecting to the specified server.  Use 0 for the default timeout, or specify whatever is the desired time to wait before giving up on the server.

Test

Press the Test button to try the connection using the specified parameters.   If successful, a Connection established information dialog will pop open.

 

Built in Geocoders

The following geocoders are built into the geocoding servers dataport:

 

 

Bing Geocoder

Street address geocoding using Bing:

  • Geocoding

  • Reverse Geocoding

  • Search by Attribute Filter Geocoding

  • Search within Radius Geocoding

  • Search within Bounding Rectangle Geocoding

 

Google Geocoder

Street address geocoding using Google.

  • Geocoding

  • Reverse Geocoding

  • Search by Attribute Filter Geocoding

  • Search within Radius Geocoding

 

Here Geocoder

Street address geocoding using Here.

  • Geocoding

  • Reverse Geocoding

  • Search by Attribute Filter Geocoding

  • Search within Radius Geocoding

  • Search within Bounding Rectangle Geocoding

 

MapBox Geocoder

Street address geocoding using MapBox.

  • Geocoding

  • Reverse Geocoding

  • Search by Attribute Filter Geocoding

  • Search within Bounding Rectangle Geocoding

 

MapQuest Geocoder

Street address geocoding using MapQuest.

  • Geocoding

  • Reverse Geocoding

  • Search by Attribute Filter Geocoding

  • Search within Radius Geocoding

  • Search within Bounding Rectangle Geocoding

 

OpenCage Geocoder

Street address geocoding using OpenCage.

  • Geocoding

  • Reverse Geocoding

 

Yandex Geocoder

Street address geocoding using Yandex

  • Geocoding

  • Reverse Geocoding

  • Search by Attribute Filter Geocoding

  • Search within Radius Geocoding

  • Search within Bounding Rectangle Geocoding

 

 

Notes

Got keys?  -  Most of the many geocoding servers Manifold lists provide free API keys for developer use.  Some provide some "reasonable" number of free geocodes per day with no key required.  Policies change quickly, and some geocoding server providers may without warning ban a user they feel has exceeded the guidelines for free use.  It is best to get an API key which allows some specific number of free or paid geocodes and to then follow the rules.   If we are in search of a free geocoder and Bing and Google do not work for us, try one of the others.  

 

NULLs - When a geocoding server returns a NULL for an address that usually means one of several  things:

 

 

Problems connecting - Check the Log Window to see what is going on behind the scenes if an attempted connection does not work.     The problem is usually a wrong connection string, failure to provide required credentials such as an key string that authorizes access, an incredibly slow server, a server that is offline or other infrastructure issues.

 

Visit the Manifold community forum and talk out difficulties with other users.  Make sure to post full information on what you are doing, the connection URL you used, all details of how you tried to connect (including all settings in the data source dialog), what happened, and what the Log Window reported.    If other users cannot help you, spending a tech support incident will produce an authoritative analysis of the issue.

 

Try the URL in a browser - Checking the URL by launching it in a browser can reveal many problems with the URL or with the web server.  If a URL does not work in a Manifold web server dataport, try exactly the same URL in a browser.  If a browser cannot connect to the URL, the Manifold web server dataport will not be able to connect to it either.  If a browser cannot connect to that URL, that indicates the problem is the URL or the web server.   For example, the web server might be offline.  Or, for example, If the browser connects to a page other than the actual web service endpoint, such as, to a web page that lists various options for web servers, that shows the URL is not a URL for a web server but a URL to some other sort of web page.   

 

Connection problems are often caused by incorrect URLs.  There might be a typographical error in the URL or the URL might not be an endpoint to a functioning server but instead a URL to some other web page.  The server responding to the URL may have geographic restrictions (surprisingly common) that does not respond to connections from IP addresses that are thought to be in a canceled country.  Trying the URL in a browser will fail in such cases.  Web servers may also have other restrictions, such as only allowing connections from white listed IP addresses, from paying clients, or from those clients that use a special security scheme.  

 

Must Have Internet - It seems obvious that to connect to a web server, including a geocoding server, we must have a live, functioning Internet connection.  What might not be obvious is that sometimes we may have only a partial Internet connection, without realizing we do not have a full Internet connection.  A classic example is using a browser, such as Opera, which may ignore failed IPv6 DNS resolution but work OK using IPv4 DNS resolution.  Without IPv6 DNS resolution we can browse Internet using Opera but we might not be able to connect to Microsoft, Google, or some other web servers.   

 

Manifold's web server connections, just like the latest Google Chrome and Microsoft Edge browsers, require full IPv6 DNS resolution.   That normally happens automatically using whatever IPv6 DNS servers are assigned by our Internet service provider, but at times IPv4 DNS continues to work OK while the IPv6 DNS servers assigned by our ISP do not work.  If we are using Opera, and not Edge or some other browser that uses IPv6 DNS resolution, we might not notice that our ISP-provided IPv6 DNS resolution is not functioning.    We might only notice the problem when trying to use an image server or other web server within Manifold and it does not work.

 

If we cannot get a display from a web server, we can check the Manifold Log Window. If the log reports that a connection cannot be made, in Windows network dialogs for our Internet connection  we can try setting the IPv6 DNS servers to some "known good" DNS servers.   A good choice is using Google's public DNS service, using the following addresses for primary and backup DNS server addresses:

 

2001:4860:4860::8888
2001:4860:4860::8844

 

 

See Also

File - Create - New Data Source

 

Street Address Geocoding

 

Example: Street Address Geocoding