Chapter 5. Exporting Spatial Data
By now you have gained experience importing and working with spatial data, so it is now time to get it out of a database. This chapter is all about exporting data from PostgreSQL/PostGIS to files or other data sources. Sharing data via the web is no less important, but it has its own specific process, and is taken care of in a separate chapter.
There may be different reasons for having to export data from a database, but certainly sharing it with others is among the most popular ones. Backing the data up or transferring it to other software packages for further processing are other common reasons for learning export techniques.
In this chapter, we'll have a closer look at the following:
- Exporting data using
\COPY
(andCOPY
) - Exporting vector data using
pgsql2shp
- Exporting vector data using
ogr2ogr
- Exporting data using GIS clients
- Outputting rasters using GDAL
- Outputting rasters using psql
- Using the PostgreSQL backup functionality
Basically, this chapter is structured...