Introduction

Beyond being a spatial database with the capacity to store and query spatial data, PostGIS is a very powerful analytical tool. What this means to the user is a tremendous capacity to expose and encapsulate deep spatial analyses right within a PostgreSQL database.

The recipes in this chapter can roughly be divided into four main sections:

  • Highly optimized queries:
    • Improving proximity filtering with KNN
    • Improving proximity filtering with KNN advanced
  • Using the database to create and modify geometries:
    • Rotating geometries
    • Improving ST_Polygonize
    • Translating, scaling, and rotating geometries – advanced
    • Getting detailed building footprints from LiDAR
  • Creating a fixed number of clusters from a set of points:
    • Using the PostGIS ...

Get PostGIS Cookbook - Second Edition now with the O’Reilly learning platform.

O’Reilly members experience books, live events, courses curated by job role, and more from O’Reilly and nearly 200 top publishers.