Custom geocoding Tableau for Belgium (and Luxembourg)

Friday, December 11, 2015 Nicolas Deruytter

I have been using Tableau Software on a daily basis for over 4 years now, and I’m living in Belgium. In Tableau Software there are basic Belgian region’s available, but not on a postal code level.

A couple of years ago I used custom geocoding to build map visualisations for a client. To my surprise there is still no blog post which clearly illustrates how to do so for Belgium. Here it is.

If you want to display information on a map, you need latitude and longitude coordinates, in any BI-tool. You could use an external file to blend your data with, but then you hit the limitations of data blending in Tableau, and you have to do it every single time you create an analysis.

Tableau automatically recognizes by default a set of geographic roles like countries, states, counties and postcodes. For Belgium only recognises the names of the provinces. Belgian postal codes are not recognized by Tableau. [read more here: http://kb.tableausoftware.com/articles/knowledgebase/mapping-basics]

So by default one could build a sample excel file, load in Tableau, and map Belgian regions.






Tableau offers an option to import a table that assigns latitude and longitude coordinates to any geographical category using the import custom geocoding option. For Belgium (and Luxembourg), we would need a .csv-file which assigns postal codes to their respective coordinates.




Next step is to declare the format of the .csv in a schema.ini file.

You need to make sure the schema.ini file corresponds 1 on 1 with the .csv-file or Tableau will generate warnings.

Next step is to import the custom geocoding: Select the folder where your freshly made files reside. 
            
After assigning the postal code with the correct geopgrahical attribute


we can build the below map for example by using the bestat open data:


If you want the schema.ini file and geocoding .csv follow this link to download the custom geocoding.


Thanks for reading,
Nicolas