Hello, right now I am trying to make a touristic map for Abakan (the capital of the Republik of the Russian Republik Khakassia). So far I used the instruction on switch2osm to load OSM Data from Geofabrik into QGIS. I used the Carto stlye sheet. Now I would like to lable streets and touristic Objects with the German or English names, but the columns for these tags are missing. I guess, I somehow could get the columns tobe created using the hstore extension, but I dont kno how to do this. Is it clear what I am asking for? Thanks alot asked 18 Jun '15, 13:45 oohay |
Please do not ask two questions in one (particularly when they are technically not related), can you open a seperate question for your 2nd part? Wrt hstore I'm assuming that you are actually loading them in to Postgres/Postgis not qgis, and likely doing that with osm2pgsql? If that is the case you can follow http://wiki.openstreetmap.org/wiki/Osm2pgsql#hstore and reimport. answered 18 Jun '15, 15:28 SimonPoole ♦ |
To import with hstore, you'll need to reimport. First run I'm afraid I don't know how to style QGis in the way you want, perhaps someone else can help. (Though like @SimonPoole, I advise you to open another question) answered 19 Jun '15, 08:41 rorym Thanks for your answers! Simon Poole is right. I am working with Postgis. And I already activated the --hstore Extension:
Than I loaded the Database in osm2pgsql by typing:
I guess, I have to change something in this last command to get the english an german Names. On the [switch2osm] (https://switch2osm.org/?s=loading+osm+data) page is written that:
But there is no special hstroe column in QGIS visble....
(19 Jun '15, 15:23)
oohay
According to this older issue tracker link (https://hub.qgis.org/issues/3989), the latest versions of QGIS should display hstore columns as text (columns?). I guess it may be doing some "on-the-fly" conversion of the data to get in a more "GIS friendly" plain text column format, but since I don't have PostGIS installed, I can't tell you for sure.
(20 Jun '15, 13:51)
mboeringa
|
Thanks a lot I rechecked my data in QGIS and found out that the English and German Names of the touristic objects are stored within the last column, which is called "tags". So my question kind of changed: How can I get two single columns with the English and German Names out of the tag column in which seem to be stored all additional tags not used by the Cartho style? Should I open a new question for that and declare my question as solved? answered 20 Jun '15, 22:02 oohay 1
Opening a new question can mean more visibility which can attract answers. To get the tags as separate columns, you can use the osm2pgsql style file to add
(21 Jun '15, 10:31)
rorym
|
Okay thats the solution to the problem: I edited the openstreetmap-carto.style document to create separate columns for the tags name:en and the tag name:de. I just added the lines to the document:
Thanks for your help! answered 22 Jun '15, 19:10 oohay |