In the UK we are very fortunate to have the Ordnance Survey who provide the whole of Britain in vector format. The data is provided as over 60 tiles, each of which contains something like 16 shapefiles for each feature type. Each shapefile is prefixed with the tile ID.
There are very good Q&As here already that deal with the general case for importing all this lovely data into PostGIS. For example:
find . -name *.shp -exec ogr2ogr -f PostgreSQL PG:'dbname=my-gis-database
active_schema=public host=localhost user=postgres password=my-password' '{}' -s_srs
EPSG:27700 -a_srs EPSG:27700 -overwrite -skipfailures -progress \;
Is it possible to import all of the data in one simple script like this so that:
- Each tile inherits from a parent table e.g. HP_rivers INHERITS (rivers)?
- The tablespace is provided to ensure it all loads onto a disk big enough to take it all in one go rather than my small but speedy SSD?
My goal is to have a single table structure which allows me to interrogate the whole of Britain or from a given tile, and to store the whole structure on a tablespace on slower but bigger disk.