AW: [postgis-users] OGR2OGR Uppercase/Lowercase

Düster Horst Horst.Duester at bd.so.ch
Fri Oct 4 06:49:30 PDT 2002


Frank,

Perhaps you misunderstood the problem. The layername isn't a problem. The
column names make the problem. Of course I can quote all column names like: 

  select "ID", "GAGA", "GAGA2" from table;

I think it's a better solution to translate all input column names to
lowercase during the import process. 

Horst

-----Ursprüngliche Nachricht-----
Von: Frank Warmerdam [mailto:warmerdam at pobox.com]
Gesendet am: Freitag, 4. Oktober 2002 13:37
An: postgis-users at postgis.refractions.net
Betreff: Re: [postgis-users] OGR2OGR Uppercase/Lowercase

Düster Horst wrote:
> Hi,
> 
> I'm faced with an uppercase/lowercase problem. After shape file import to
> Postgresql with OGR2OGR all shape file based column names were stored
> uppercase. Postgresql isn't able to process columns with uppercase names.
> How to handle this problem? Any hint????


Düster,

I would suggest re-ipmorting them overriding the layer name with the lower
case equivelent.  Something like:

ogr2ogr PG:dbname=warmerda ABC.SHP -nln abc ABC

I think I will need to add a creation option to "launder" layer names into
something easier to use in PostgreSQL.  There have been complaints before.

Incidently, you can still use the tables in PostgreSQL with upper case names
... you would just need to quote the names appropriately.

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



_______________________________________________
postgis-users mailing list
postgis-users at postgis.refractions.net
http://postgis.refractions.net/mailman/listinfo/postgis-users




More information about the postgis-users mailing list