Scripts to convert AddressBase™ Premium CSV files into register-shaped data.
The names of the fields in the generated data have been picked to be consistent with other registers, whilst remaining compatible with the BS7666 standard and have been informed by Open Addresses UK.
- address — The UPRN of the property or premises being addressed
- street — the Unique Street Reference Number (USRN)
- street-custodian — Geoplace LLP code for the local custodian for an address
- parent-address — a reference to the address which contains this address
- primary-address — a reference to the BS7666 primary addressable object, where found
- name — the BS7666 secondary addressable object name as a single field
- name-cy — an alternative name, in Welsh
- point — an indication of the geographic location of an address
- start-date — the date from which an entry becomes applicable
- end-date — the date from which an entry becomes no longer applicable
- street — the Unique Street Reference Number (USRN)
- street-custodian — Geoplace LLP code for the local custodian for a street
- name — the street name
- name-cy — an alternative street name, in Welsh
- place — a reference to the place discovery register, matched to the:
- locality — the name of a locality
- town — the name of a nearby town
- administrative-area — the name of the administrative area
- point — an indication of the geographic location of the street
- start-date — the date from which an entry becomes applicable
- end-date — the date from which an entry becomes no longer applicable
A local copy of AddressBase™ Premium, which includes the geographic location of addresses and historical entries is needed to build the register-shaped data.
Ordnance Survey publish the National Address Gazetteer as AddressBase™ once every six weeks, see the timetable of releases and release notes.
AddressBase™ Premium is obtainable by government organisations who are members of the Public Sector Mapping Agreement (PSMA) from the Ordnance Survey portal.
The data can be ordered using the session-based shopping cart system. We have not found a way to automate this process:
- visit the Ordnance Survey portal.
- visit the orders page
- order a new copy AddressBase™ Premium 5km Download in CSV format "Full Supply"
- "order more"
- select the whole map - map didn't load in Safari macOS Sierra, worked in Firefox, requires you have Adobe Flash player installed
- add the order to your basket
- visit your basket, checkout
- "place your order"
- visit the list of orders for your organisation
- keep refreshing this page until sometime later (allow several minutes to elapse) a download page for your order will appear in the list of downloads for your organisation
- visit the download page (not a bookmarkable URL) and use your browser to save the page as
cache/download.html
Use make to download the AddressBase CSV files in the cache/AddressBase
directory,
if you have an old download then remove cache/AddressBase
first:
$ rm -rf ./cache/AddressBase
$ make download
Building depends upon Go:
$ make init
$ make -j4
Register-shaped tab-separated value files are produced in the data directory, one file per-street-custodian.
A log of any issues encountered is produced in the log
directory.
- AddressBase Premium documentation
- NLPG Data entry conventions
- UPRN classification codes
- UPRN lifecycle
The software in this project is open source, covered by LICENSE file.
The copyright and licensing of the source data is not open and falls under terms of Ordnance Survey AddressBase™.