[gdal-dev] [MITAB] Unsupported case or corrupt file

Daniel Morissette dmorissette at mapgears.com
Mon Dec 21 09:18:28 EST 2009


Which version of GDAL/OGR are you using?

Can you please try to convert your dataset from TAB to MIF using the 
tab2tab program available at http://mitab.maptools.org/ and see if you 
get the same error?

About QGIS, yes, AFAIK it uses OGR (and MITAB) to read TAB files, so the 
difference in behavior may be related to different versions of the libs 
being used.

Daniel


RICHARD Didier wrote:
> Hi all,
> 
> I'm trying to read a (big) mapinfo TAB file and I'm facing the following
> error (source is the today's trunk) with ogr2ogr as well as ogrinfo :
> 
> ____
> $ ogrinfo -al rall.TAB
> Had to open data source read-only.
> INFO: Open of `rall.TAB'
>       using driver `MapInfo File' successful.
> 
> Layer name: rall
> Geometry: Unknown (any)
> Feature Count: 6138177
> Extent: (-5.053907, 41.367176) - (9.559522, 51.075147)
> Layer SRS WKT:
> GEOGCS["unnamed",
>     DATUM["WGS_1984",
>         SPHEROID["WGS 84",6378137,298.257223563],
>         TOWGS84[0,0,0,-0,-0,-0,0]],
>     PRIMEM["Greenwich",0],
>     UNIT["degree",0.0174532925199433]]
> ID: Integer (0.0)
> ERROR 7: Unsupported case or corrupt file: MULTIPLINE/REGION object
> vertices do not appear to be grouped together.
> ERROR 3: Failed reading coordinate data at offset 210440
> ____
> 
> With debug on there is no more usefull information.
> My objective is to put this dataset into postgresql.
> 
> The mapinfo files I'm trying to read are as follows (ls -lh):
> 
> ____
>   135 rall.TAB
>  1,2G rall.MAP
>   24M rall.ID
>   30M rall.DAT
> ____
> 
> In mitab_mapcoordblock.cpp (line 503) when the error occurs I have got the
> following values :
> i=0 numSections=1
> nVextexOffset=-16384003
> numVertices=24
> numVerticesTotal=24
> 
> The negative offset is the cause of the error, but it is declared as an
> int. Is this right ?
> 
> I have not found any tickets about this kind of error.
> 
> Any idea on how to fix this (I could read the TAB file with QGIS 1.3.0 but
> not sure if QGIS is using GDAL/OGR for reading files)?
> 
> 
> Regards


-- 
Daniel Morissette
http://www.mapgears.com/


More information about the gdal-dev mailing list