O'Reilly logo

OpenStreetMap by Jonathan Bennett

Stay ahead with the world's most comprehensive technology and business learning platform.

With Safari, you learn the way you learn best. Get unlimited access to videos, live online training, learning paths, books, tutorials, and more.

Start Free Trial

No credit card required

Using Osmosis with a database

So far, we've only used Osmosis to process OpenStreetMap data in local XML files. It can also read and write data to a database, which is more complex to set up, but faster for many operations. Setting up a database for the data can be complicated, but you only need to do it once.

Osmosis supports three types of databases:

  • PostGIS with a simple schema
  • The OpenStreetMap API schema on PostgreSQL
  • A legacy API schema on MySQL

We'll cover the first of these in this chapter. The second format is used when handling data on the OpenStreetMap servers, and isn't intended for use with any other system. The last format is no longer actively supported, as it isn't used on OpenStreetMap's servers any more, and you shouldn't use this ...

With Safari, you learn the way you learn best. Get unlimited access to videos, live online training, learning paths, books, interactive tutorials, and more.

Start Free Trial

No credit card required