|
Re: [OSM-dev] DBF files (shapefile) and OSM tags: msg#00132gis.openstreetmap.devel
On Fri, Dec 29, Nick Whitelegg wrote: > Am now working on an OSM to shapefile converter. Using shapelib, shapefiles > seem fairly straightforward but the accompanying .dbf file is a little more > unclear. The general idea seems to be to describe attributes in a database > table-like structure, with each column representing a different attribute. Strictly speaking, a "shapefile" is a data entity consisting of three separate files: A .shp, a .dbf and a .shx file. > The only thing is, with the free-form nature of OSM attributes, the number of > columns required in the .dbf table would quickly spiral considerably > particularly for nodes (less for ways, as for ways there are only a number of > common tags e.g. highway). So might it be better to concatenate the key/values > as a comma separated list (e.g > amenity=place_of_worship,denomination=anglican,name=St Pauls Church) and put > that in one DBF column? The columns in a shapefile's attributes have a fixed width, and that width is reserved for each shape. So the space usage will be approximately equal between using a single, concatenated column and multiple columns. What did you intend to gain by concatenating the columns? \\kristian -- Cthulhu.call(); |
|
| <Prev in Thread] | Current Thread | [Next in Thread> |
|---|---|---|
| Previous by Date: | [OSM-dev] DBF files (shapefile) and OSM tags: 00132, Nick Whitelegg |
|---|---|
| Next by Date: | [OSM-dev] Fw: DBF files (shapefile) and OSM tags: 00132, Nick Whitelegg |
| Previous by Thread: | [OSM-dev] DBF files (shapefile) and OSM tagsi: 00132, Nick Whitelegg |
| Next by Thread: | [OSM-dev] Fw: DBF files (shapefile) and OSM tags: 00132, Nick Whitelegg |
| Indexes: | [Date] [Thread] [Top] [All Lists] |
| News | FAQ | advertise |