[postgis-tickets] [PostGIS] #2417: pgsql2shp doesnt see SRID
PostGIS
trac at osgeo.org
Sun Sep 22 14:26:06 PDT 2013
#2417: pgsql2shp doesnt see SRID
----------------------------+-----------------------------------------------
Reporter: darkblueb | Owner: pramsey
Type: defect | Status: reopened
Priority: medium | Milestone: PostGIS 2.1.1
Component: documentation | Version: 2.0.x
Resolution: | Keywords: srid, pgsql2shp
----------------------------+-----------------------------------------------
Changes (by robe):
* milestone: PostGIS Future => PostGIS 2.1.1
Comment:
How about this
{{{
CREATE TABLE new_table AS
SELECT
pkey, ST_Transform( geom, 4326)::geometry(POINT,4326) As geom
FROM
existing_valid_table;
}}}
Does it in one step and registers correctly.
You could also just pass an sql statement and avoid the whole create table
step as I noted already. If you used an SQL statement it would register
right because it wouldn't find any answer in geometry_columns so as I
stated before this should work just fine.
{{{
pgsql2shp -f test_shapefile.shp "SELECT * from ne3_test" shp_test
}}}
If you can put together a documentation patch to save me the trouble of
explaining this that would be really swell.
--
Ticket URL: <http://trac.osgeo.org/postgis/ticket/2417#comment:8>
PostGIS <http://trac.osgeo.org/postgis/>
The PostGIS Trac is used for bug, enhancement & task tracking, a user and developer wiki, and a view into the subversion code repository of PostGIS project.
More information about the postgis-tickets
mailing list