You are not logged in.
- Topics: Active | Unanswered
Announcement
Please create new topics on the new site at community.openstreetmap.org. We expect the migration of data will take a few weeks, you can follow its progress here.***
Pages: 1
#1 2008-11-18 23:18:00
- Eddard Stark
- Member
- Registered: 2008-11-18
- Posts: 2
Get Metro Stations Coordinates
Hi guys,
First of all: I am completely new to Openstreetmap and I am looking forward to get more information.
I am trying to develop a very simple java program to query the OSM server.
Here is my problem:
I would like to simply get the latitude, longitude, name and line number of all the metro stations of Milan (Italy).
I have seen the map in the main page of Openstreetmap and they are all displayed.
I was wondering how to write a java program to query the DB and get all this information.
Is it possible ?
How can I access the data base ?
How can I do the query?
Thank you in advance !
Bye
Offline
#2 2008-11-20 00:57:43
- emj
- Member
- From: .se (59.3N17.99E) 0735969076
- Registered: 2006-06-18
- Posts: 949
Re: Get Metro Stations Coordinates
xapi: the extended api lets you query for the tag railway=station(not sure if that is the correct tag look it up in map features )
the osm api lets you download history of those objects if you want to
osm list of tags tells you what you should search for. (this is called map features)
e.g. in xapi you can query like this:
http://www.informationfreeway.org/api/0.5/node[railway=*][bbox=left,bottom,right,top]I recommend using the osm export function (linking Rome here), to get the right bounding box, easy to use and graphical. You still need to copy coordinates from the input boxes.
Last edited by emj (2008-11-20 00:58:22)
Offline
#3 2008-11-20 11:07:37
- Eddard Stark
- Member
- Registered: 2008-11-18
- Posts: 2
Re: Get Metro Stations Coordinates
Thank you emj !
I'll try straightaway !
Offline
#4 2008-11-20 14:02:44
- emj
- Member
- From: .se (59.3N17.99E) 0735969076
- Registered: 2006-06-18
- Posts: 949
Re: Get Metro Stations Coordinates
Please show us the results later on. :-) Would be fun to see what you are trying to do..
Offline
Pages: 1