[postgis-users] load shapefiles in GB2312

Akio Takubo takubo at saruga-tondara.net
Wed Feb 22 10:24:21 PST 2006


Hello,

On Wed, 22 Feb 2006 02:13:14 -0800 (PST)
Zhiqiang Zhang <zqzhang01 at yahoo.com> wrote:

> For a shapefile in GB2312 encoding, what is the
> correct way to load it into postgis db using
> shp2pgsql?
> 
> The following was attempted but seems to produce a sql
> file with all i18n encoded attribute values as blank
> string "    ".
> 
> shp2pgsql -W GB2312 test roads > roads.sql

 Your exapmle means your dbf's contents convert to utf8 from GB2312. 
roads.sql will have all attributes with utf8.
 What you to do depends on your DB's encoding and your client's locale.
(and your dbf's encoding).

 Thanks,

-- 
    Akio Takubo    from Tokyo, Japan
	takubo at saruga-tondara.net
===================================================



More information about the postgis-users mailing list