[gdal-dev] overwrite shapefile
ramirogonzalez at suremptec.com.ar
Thu May 26 09:52:22 EDT 2011
The ticket number is 4095.
2011/5/24 Chaitanya kumar CH <chaitanya.ch at gmail.com>
> You can use the OGRLayer::TestCapability() method to check write capability
> of a layer. However, there are going to be errors if another process
> accesses the files in the mean while.
> When ogr2ogr is executed with -append, -overwrite or --update options, it
> should error out with the message "Unable to open existing output
> datasource" if a file cannot be opened to write. Can you raise a new ticket
>  describing this problem?
> : http://trac.osgeo.org/gdal/newticket
> On Wed, May 25, 2011 at 12:20 AM, Ramiro Gonzalez <
> ramirogonzalez at suremptec.com.ar> wrote:
>> I want to overwrite a shapefile using ogr(c++). If the dbf file in the
>> destination shapefile is already open by anather program(exel), the
>> operation fails in the middle and only the shp and shx files are updated.
>> How could I check, using OGR, if the dbf(or any other file in the
>> shapefile) is blocked before I overwrite it?
>> I tested this with "ogr2ogr -overwrite destination source.shp" and the
>> same thing happens
>> gdal-dev mailing list
>> gdal-dev at lists.osgeo.org
> Best regards,
> Chaitanya kumar CH.
> /tʃaɪθənjə/ /kʊmɑr/
> 17.2416N 80.1426E
-------------- next part --------------
An HTML attachment was scrubbed...
More information about the gdal-dev