[H-GEN] Extracting info from XML open street map file

Russell Stuart russell-humbug at stuart.id.au
Tue Jan 26 07:13:50 EST 2016


On Tue, 2016-01-26 at 07:41 +0000, mick wrote:
> > > Generic key/value lines:
> > > ========================
> > > 		<tag k="107" v="96"/>
> > > 		<tag k="1744_field_ref" v="143"/>
> > > 		<tag k="1744_field_ref" v="94"/>
> > > 		<tag k="1860name" v="Aberargie Mill (Corn & Flour)"/>
> > > 
> read through keys.txt and add line in the osm2pgsql .style file
> run osm2pgsql with the *.style to create postgis database
> import database into Qgis for use.
> 
> OsmType is the object type (node = point, way=line or polygon.
...
> osm2pgsql .style:
> ================
> # OsmType	Tag			DataType	Flags
> =============================================================
> node,way	107			text		delete
> node,way	1744			text		delete
> node,way	1860name		text		delete
>
> Hope this makes more sense

It makes sense in that I gather you add one line to the .style file per
unique "<tag k='value'", and the Tag column of that line is the 'value'
truncated at the first underscore if it contains one.  But you don't say
how you decide what to put the other columns (OsmType, DataType and
Flags) in that line.



More information about the General mailing list