Getting invalid stoi argument #2377
|
I’m trying to import OSM PBF data into Azure PostgreSQL 17 on Windows 10 using osm2pgsql, but I keep getting this error: Already tried classic mode with --hstore, fresh tables, and new --prefix |
Replies: 5 comments 4 replies
|
Can you please provide the exact command line, where we can get the tag transformed used, the source of the data, and the version of osm2pgsql? |
|
Here is the exact command
osm2pgsql --verbose --create --database osm --user osmdataloader -W -S "default.style" --output pgsql --host "xxxxx-postgres.postgres.database.azure.com" --hstore --hstore-add-index "I:\Apps\osm2pgsql-latest-x64\osm2pgsql-bin\europe-latest.osm.pbf"
Have tried version 1.8.1 and 2.1.1 with data from geofabrik
https://download.geofabrik.de/
|
|
Please try with a recent master version of osm2pgsql, for example the one downloaded here. There are know issues with the ones generated from Windows-2019 images. If that doesn't help, please provide the full output. We'd need to know when exactly the error happens. |
|
Can you run this command in your database please: |
|
There are two problems here: One is the not very informative error "Error: invalid stoi argument". That has been fixed in 79bc89c. You should now get an error that the PostGIS version could not be detected. The other is the problem that it seems Azure doesn't show a proper version numer. That's nothing we have any control over. |

There are two problems here:
One is the not very informative error "Error: invalid stoi argument". That has been fixed in 79bc89c. You should now get an error that the PostGIS version could not be detected.
The other is the problem that it seems Azure doesn't show a proper version numer. That's nothing we have any control over.