Re: [gdal-dev] DBF handling

2013-01-04 Thread Luca Sigfrido Percich
Hi Even, thank you for the explanation. I checked back my script, it used -fieldTypeToString real, and the TeleAtlas shapefiles stored the ID in a real(15.0) field. That's why it worked for me. Sig Il giorno ven, 04/01/2013 alle 14.53 +0100, Even Rouault ha scritto: > Selon Luca Sigfrido Percic

Re: [gdal-dev] DBF handling

2013-01-04 Thread Even Rouault
Selon Luca Sigfrido Percich : > Uffe, > > I have had a similar problems with TeleAtlas shapefiles with IDs stored > as long Numeric fields. > > I resorted to the ogr2ogr -fieldTypeToString option [1] to tell ogr to > convert to string all the mumeric fields, which is still an imperfect > workaroun

Re: [gdal-dev] DBF handling

2013-01-04 Thread Uffe Kousgaard
I am also working with TeleAtlas (now called TomTom) data. I have written a small command-line application which takes two parameters, name of DBF and which field I want as Char. This way I can control exactly which fields are changed in the process. So, it isn't all that manual :-) If you wa

Re: [gdal-dev] DBF handling

2013-01-04 Thread Luca Sigfrido Percich
Uffe, I have had a similar problems with TeleAtlas shapefiles with IDs stored as long Numeric fields. I resorted to the ogr2ogr -fieldTypeToString option [1] to tell ogr to convert to string all the mumeric fields, which is still an imperfect workaround but at least will keep you from manually ch

Re: [gdal-dev] ogr2ogr

2013-01-04 Thread Daniel Morissette
As Yves pointed out, this is a known issue, actually a regression in the MITAB driver introduced in GDAL 1.9.x: https://trac.osgeo.org/gdal/ticket/3853 Daniel On 13-01-04 5:17 AM, Uffe Kousgaard wrote: Hello, Thank you, yes I had just found the exe files in a sub folder. But it still does

Re: [gdal-dev] DBF handling

2013-01-04 Thread Even Rouault
Selon Uffe Kousgaard : > When DBF files has numeric fields with values > 2GB, processing fails > and all values come out as -2147483648. > > My current work-around is manually changing the fields from Numeric to > Char (changing the header of the DBF), but it is really an ugly hack and > spaces fo

Re: [gdal-dev] DBF handling

2013-01-04 Thread Uffe Kousgaard
Hi, It is a bug I'm reporting. I am being supplied with multiple SHP files, which I am trying to convert to a single TAB as fast and simple as possible, so bringing a 3rd format into the picture really doesn't help. The DBF still has too many digits for OGR to process them correctly. Reg

Re: [gdal-dev] DBF handling

2013-01-04 Thread Norman Vine
On Jan 4, 2013, at 5:37 AM, Uffe Kousgaard wrote: > When DBF files has numeric fields with values > 2GB, processing fails and all > values come out as -2147483648. > > My current work-around is manually changing the fields from Numeric to Char > (changing the header of the DBF), but it is rea

[gdal-dev] DBF handling

2013-01-04 Thread Uffe Kousgaard
When DBF files has numeric fields with values > 2GB, processing fails and all values come out as -2147483648. My current work-around is manually changing the fields from Numeric to Char (changing the header of the DBF), but it is really an ugly hack and spaces for padding are wrong (numeric fi

Re: [gdal-dev] ogr2ogr

2013-01-04 Thread Yves Jacolin
Hello, Le vendredi 4 janvier 2013 11:17:43 Uffe Kousgaard a écrit : > Hello, > > Thank you, yes I had just found the exe files in a sub folder. > > But it still doesn't write the TAB file correct. > > If I use MIF instead as output format, it changes Numeric(4,0) fields > into Integer(4). There

Re: [gdal-dev] ogr2ogr

2013-01-04 Thread Uffe Kousgaard
Hello, Thank you, yes I had just found the exe files in a sub folder. But it still doesn't write the TAB file correct. If I use MIF instead as output format, it changes Numeric(4,0) fields into Integer(4). There is no such thing as Integer(4) in MIF. It is either Decimal(4,0) or just Integer

Re: [gdal-dev] ogr2ogr

2013-01-04 Thread Yves Jacolin
Hello, You see this website : http://www.gisinternals.com/sdk/ or this one : http://trac.osgeo.org/gdal/wiki/DownloadingGdalBinaries (see Windows and OSGeo4W sections). Y. Le vendredi 4 janvier 2013 10:47:29 Uffe Kousgaard a écrit : > Where can I find the most recent precompiled ogr2ogr package

[gdal-dev] ogr2ogr

2013-01-04 Thread Uffe Kousgaard
Where can I find the most recent precompiled ogr2ogr package for windows? I am still using the one in fwtools 2.4.7 (almost 3 years old) and I have some utf-8 encoded SHP files, which it doesn't seem to handle well. I have tried with cpg files, but no luck. Regards Uffe Kousgaard ___

[gdal-dev] ogr2ogr

2013-01-04 Thread Uffe Kousgaard
Where can I find the most recent precompiled ogr2ogr package for windows? I am still using the one in fwtools 2.4.7 (almost 3 years old) and I have some utf-8 encoded SHP files, which it doesn't seem to handle well. I have tried with cpg files, but no luck. Regards Uffe Kousgaard __