Versions Compared

Key

  • This line was added.
  • This line was removed.
  • Formatting was changed.

...

Finally, download the OSM data. As an example we will use Mexico as our subset of data. The file we used was downloaded from http://download.geofabrik.de/central-america/mexico-latest.osm.bz2. Extract the contents to a location on the hard drive.

There is an alternative way. OSM can be filtered before downloading, please check http://wiki.openstreetmap.org/wiki/Overpass_API. For Coastlines the following query can be used in the so called Overpass Turbo OSM Api.

/*
This has been generated by the overpass-turbo wizard.
The original search was:
“Coastline”
*/
[out:json][timeout:25];
// gather results
(
  // query part for: “Coastline”
  way["natural"="coastline"]({{bbox}});
);
// print results
out body;
>;
out skel qt;

The following two commands will perform the database operations necessary for creating the tables in the database that was just created.

...