This is a static archive of our old OpenStreetMap Help Site. Please post any new questions and answers at community.osm.org.

[closed] Osmosis import - Files was unexpected at this time

0

Hi,

I am trying to import an .osm file to my postgres database but I keep getting the following error: Files was unexpected at this time.

Command I used to import the file: osmosis --read-xml file="D:\Licenta\Romania OSM\romania.osm" --write-apidb host="localhost:5432" database="romania" user="postgres" password="mypostgrespassword"

Any idea why I am getting this error?

Thank you

asked 20 Mar '13, 12:53

raduzugravu's gravatar image

raduzugravu
316610
accept rate: 0%

closed 25 Mar '13, 14:41

SomeoneElse's gravatar image

SomeoneElse ♦
36.9k71370866

The question has been closed for the following reason “The questioner has answered their own question and provided the resolution for the benefit of others.” by SomeoneElse 25 Mar ‘13, 14:41


One Answer:

1

I solved this problem by setting the correct path to java.exe. You can do this by editing osmosis.bat in bin directory and setting JAVACMD to the correct path. This worked for me.

answered 25 Mar '13, 14:29

raduzugravu's gravatar image

raduzugravu
316610
accept rate: 0%

Source code available on GitHub .