[postgis-users] help with Microstation DGN data to PostGIS

ejansson at COLLEGES.ORG ejansson at COLLEGES.ORG
Wed Jul 9 08:02:43 PDT 2003


I've been been trying to load a number of files in Microstation DGN format into
PostGIS, and was hoping someone here had some experience doing this.  I've been
using the ogr2ogr utility to do this: 

    ogr2ogr -lco LAUNDER=YES -f "PostgreSQL" PG:dbname=testdb D4d10.97.1.dgn

..but have found that the attribute data attached to my shapes is not being
loaded into the database.  I have also tried using the ogr2ogr utility to create
shapefiles, and then use shp2pgsql to get that data into PostGIS:

    ogr2ogr -skipfailures -nln D4d10.97.1_polygon -skipfailures -lco
SHPT=POLYGON -f "ESRI Shapefile" D4d10.97.1/ D4d10.97.1.dgn

..which works, excepth that, again, the attribute data does not appear: the SHP
file has all the geometry data, but the DBF file is empty.  When I use ArcView
and do a manual "Convert to Shapefile..." all the attribute data converts fine.
 The problem is, I have several hundred of these files to convert.

Sorry if this is a peripheral topic to this list--I realize most users are
probably most concerned with shapefiles and not DGNs.  Thanks in advance for any
help.

Eric Jansson



More information about the postgis-users mailing list