2012/4/12 superman0920 <superman0...@gmail.com>:
> Hi
> I input data from MIF files by ogr2ogr.
> I find the string column use char type. For example, the column defined NAME
> char(100) and the value is TEST.
> I selected that column, the value is TEST and 96 spaces.
> How can I assign the type of column when I import

Superman,

>From http://www.gdal.org/ogr/drv_pg.html we see that
the layer creation option PRECISION can be set to NO
to disable preserving precision and instead use VARCHAR.

eg.

ogr2ogr -lco PRECISION=NO ...

> and how can I assign the name of the geometry column?

The same page mentions you can use the GEOMETRY_NAME layer
creation option to control the name of the geometry column in the
created table.

Best regards,
-- 
---------------------------------------+--------------------------------------
I set the clouds in motion - turn up   | Frank Warmerdam, warmer...@pobox.com
light and sound - activate the windows | http://pobox.com/~warmerdam
and watch the world go round - Rush    | Geospatial Software Developer
_______________________________________________
postgis-users mailing list
postgis-users@postgis.refractions.net
http://postgis.refractions.net/mailman/listinfo/postgis-users

Reply via email to