I am using this query :

"GET /cgi/interpreter?data=[out:json];   (node(20.25527,85.8244,20.26632,85.83685);way(20.25527,85.8244,20.26632,85.83685);node(w)->.x;);out; HTTP/1.1\r\n"

And for example there is this way :

{
  "type": "way",
  "id": 26764919,
  "nodes": [
    293465191,
    293465090,
    293465086,
    293465082,
    293465081
  ],
  "tags": {
    "highway": "secondary"
  }

In the nodes returned by query some nodes in above list eg, 293465086 is missing. So I am unable to completely render the way. Am I using the correct query ? If not what query should I use to render all ways in my bounding box ? Is the above query not returning the nodes out of the bounding box ?

asked 29 Jan '13, 13:34

Anubha's gravatar image

Anubha
31336
accept rate: 0%

edited 29 Jan '13, 13:35


Do you execute your query here? Please re-run the query. I get node 293465086 in the results as well as 33 member nodes for way 26764919, so I cannot yet reproduce the problem.

permanent link

answered 29 Jan '13, 19:40

Roland%20Olbricht's gravatar image

Roland Olbricht
6.3k35685
accept rate: 35%

well, thanks so much, the nodes are really all present, so I debugged my code and found out why the nodes were not found. after executing the query, I saved the results in a text file. In that text file, some nodes were not in proper format, eg. { "type": "node", "id": 293454101 1000 / this 1000 value is extra / , "lat": 20.2622200, "lon": 85.8301700 }, and so my program could not parse due to this 1000, this 1000 was inserted unwanted in other places too. my line to write to file fprintf(fp,"%s",&buf[0]); why could this be happening ?

(30 Jan '13, 05:27) Anubha

to state the above problem more clearly than in a comment I asked the following question :

https://help.openstreetmap.org/questions/19424/this-program-to-retrieve-the-nodes-and-ways-returns-some-extra-garbage-values

(30 Jan '13, 06:36) Anubha
Your answer
toggle preview

Follow this question

By Email:

Once you sign in you will be able to subscribe for any updates here

By RSS:

Answers

Answers and Comments

Markdown Basics

  • *italic* or _italic_
  • **bold** or __bold__
  • link:[text](http://url.com/ "title")
  • image?![alt text](/path/img.jpg "title")
  • numbered list: 1. Foo 2. Bar
  • to add a line break simply add two spaces to where you would like the new line to be.
  • basic HTML tags are also supported

Question tags:

×372
×341
×257
×173
×111

question asked: 29 Jan '13, 13:34

question was seen: 2,445 times

last updated: 30 Jan '13, 06:36

powered by OSQA