[Gdal-dev] append option in ogr2ogr

Hans Verlouw Hans.Verlouw at Geodan.nl
Wed Jun 2 05:16:58 EDT 2004


Hi list,

I noticed some strange behaviour when using the 'append' option of ogr2ogr.
I have twelve 2-dimensional ESRI shape files that I want to convert to one 
single table in Oracle Spatial 9i.
When I convert one shape file and explicitly specify the -lco DIM=2 option, 
the result is OK, so SDO_GTYPE = 2007 for all records.

But after I append other shape files (which are 2D originally too) the 
resulting Oracle table gets over 90% records that are 3D,
so with SDO_GTYPE = 3007

For every step I specify the -lco DIM=2 option.

Am I doing something wrong here?
I also use the OVERWRITE=YES flag, but I don't think this is the problem, 
because the table is growing at every step.

A snippet of my batch file:

ogr2ogr         -f OCI OCI:%USER%/%PASS%@%DB% 
%DATA%\Flevoland_tblEdugis_ObjRecht_region.shp                -lco 
SRID=90112 -lco DIM=2 -lco LAUNDER=YES -lco OVERWRITE=YES -nlt MULTIPOLYGON 
-nln objrecht
ogr2ogr -append -f OCI OCI:%USER%/%PASS%@%DB% 
%DATA%\Zeeland_tblEdugis_ObjRecht_region.shp                  -lco 
SRID=90112 -lco DIM=2 -lco LAUNDER=YES -lco OVERWRITE=YES -nlt MULTIPOLYGON 
-nln objrecht

ogr2ogr -append -f OCI OCI:%USER%/%PASS%@%DB% 
%DATA%\Drenthe_tblEdugis_ObjRecht_region.shp                  -lco 
SRID=90112 -lco DIM=2 -lco LAUNDER=YES -lco OVERWRITE=YES -nlt MULTIPOLYGON 
-nln objrecht
ogr2ogr -append -f OCI OCI:%USER%/%PASS%@%DB% 
%DATA%\Friesland_tblEdugis_ObjRecht_region.shp                -lco 
SRID=90112 -lco DIM=2 -lco LAUNDER=YES -lco OVERWRITE=YES -nlt MULTIPOLYGON 
-nln objrecht


Thanks in advance,

Hans





Met vriendelijke groeten,

Hans Verlouw
-------------------------------------
Geodan IT b.v.
Buitenhaven 27-A
5211 TP 's-Hertogenbosch (NL)
-------------------------------------
Tel: +31 (0)73 - 692 5151
Fax:  +31 (0)20 - 5711 333
-------------------------------------
Postadres / mailing address
President Kennedylaan 1
1079 MB Amsterdam (NL)
-------------------------------------
E-mail: Hans.Verlouw at Geodan.nl
Website: www.geodan.nl
Disclaimer: www.geodan.nl/disclaimer
-------------------------------------





More information about the Gdal-dev mailing list