1

I am trying to join the OS Building Heights CSV file with the OS MasterMap Topography Layer. They have both been paid / they are NOT the free OS data and so definitely include the data I need. This is in order to create a building height plan of my study area.

Having googled it numerous times, I am under the impression that I need to join the TOID field in the OS MasterMap Topo layer with the equivalent number in, what is called, 'field 1' of the building heights CSV file.

Problem is... when they join, all the 'new' fields which have been joined all say 'NULL'. An example of the number in 'field 1' is osgb1000002107214922 and an example of a number in TOID is 0001000034928367. So the Building Heights CSV file displays 'osgb' before the number and the OS Topo does not.

There is far too much data to go through and add in/remove the 'osgb', so does anyone have any other solutions or know where on earth I am going wrong?

Or could explain to me how to join these datasets in QGIS?

1

The trick here is to create a "virtual" attribute that will match the fields in your text file.

  1. Select your polygons

  2. Select Field Calculator and create a new virtual field

    enter image description here

    In this example I needed to stick two fields together but you would need something like 'osgb' || toid (if your field is called toid).

  3. Then you can go to the Join tab of the properties screen and use the new field as if it was a normal attribute for joining the two files together.

    enter image description here

0

The OS MasterMap Topography Layer support page is the reference that you are looking for. It includes Product + Technical documentation for both of the datasets you mention.

Of particular interest will be...

  1. The Building Height Attribute getting started guide (PDF) which provides lots of useful information about the BHA data (including reformatting the TOIDs; and how to join the CSV to the OS MasterMap Topography Layer).

  2. The Building Height Attribute header which contains the CSV data field headers.

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.