[FWTools] Problems with GML to Shapefile
Frank Warmerdam
warmerdam at pobox.com
Mon Jan 12 10:11:35 EST 2009
Paul Wittle wrote:
> Hello,
>
> I'm having trouble running the following code from a batch file and I
> can't work out what is wrong.
>
> C:\FWTools2.2.8\bin\ogr2ogr.exe -f "ESRI Shapefile"
> "C:\Import\shape\1_CS.shp" "C:\Import\gml\1.gml" CS -a_srs EPSG:4277 -update
>
> [my install dir for FWTools] -f [convert to] [output shapefile name]
> [input gml layer] [layer in gml] [OSGB projection] [update file if it
> exists]
>
> As far as I can tell it worked on one computer and not on another, am I
> missing something fundamental in terms of the declaration?
Paul,
What error do you get?
Are you running the command from within the FWTools shell? There are
several environment variables needed for correct operation of ogr2ogr,
and they are normally defined in the FWTools shell environment, but not
outside it. In particular, EPSG:4277 won't be correctly expanded unless
the GDAL_DATA environment variable is set.
Best regards,
--
---------------------------------------+--------------------------------------
I set the clouds in motion - turn up | Frank Warmerdam, warmerdam at pobox.com
light and sound - activate the windows | http://pobox.com/~warmerdam
and watch the world go round - Rush | Geospatial Programmer for Rent
More information about the FWTools
mailing list