Troche mnie już to przerasta ale coś zaczełem robić:
Zainstalowałem PostreQSL i PostGis wg instrukcji http://wiki.openstreetmap.org/wiki/Mapnik/PostGIS

for Ubuntu >=12.04:

sudo apt-get install postgresql-9.1-postgis postgresql-contrib-9.1
sudo -u postgres -i -H
createuser -SdR gisuser
createdb -E UTF8 -O gisuser gis
createlang plpgsql gis
psql -d gis -f /usr/share/postgresql/9.1/contrib/postgis-1.5/postgis.sql

to populate the table spatial_ref_sys (mandatory for use with osm2pgsql):

psql -d gis -f /usr/share/postgresql/9.1/contrib/postgis-1.5/spatial_ref_sys.sql

common for all three

psql gis -c “ALTER TABLE geometry_columns OWNER TO gisuser”
psql gis -c “ALTER TABLE spatial_ref_sys OWNER TO gisuser”
exit

Po wpisaniu: psql gis gisuser i \d
wyświetla mi się:
List of relations
Schema | Name | Type | Owner
--------±------------------±------±---------
public | geography_columns | view | postgres
public | geometry_columns | table | gisuser
public | spatial_ref_sys | table | gisuser

Rozumiem że teraz muszę wysłać odpowiednie zapytanie:
coś w stylu:
psql gis “select way from planet_roads where ST_Intersects(way,ST_GeomFromText(‘POLYGON((14 49, 24 49, 24 55, 14 55, 14 49))’,4326))” ??

czy planet_roads ma być ścieżką dostępu do pliku OSMowego? Ok, sprawdziłem te punkty biorą w kwadrat całą powierzchnię Polski. A czym jest liczba 4326 na końcu zapytania?
Co właściwie zwróci mi te zapytanie?