[postgis-devel] [PostGIS] #1759: shp2pgsql st_transform not unique requires casting

PostGIS trac at osgeo.org
Wed Jun 20 16:08:17 PDT 2012


#1759: shp2pgsql st_transform not unique requires casting
----------------------------+-----------------------------------------------
  Reporter:  robe           |       Owner:  mcayland     
      Type:  defect         |      Status:  reopened     
  Priority:  blocker        |   Milestone:  PostGIS 2.0.1
 Component:  loader/dumper  |     Version:  2.0.x        
Resolution:                 |    Keywords:               
----------------------------+-----------------------------------------------
Changes (by robe):

  * status:  closed => reopened
  * resolution:  fixed =>


Comment:

 Evidentally I missed testing this on geography:

 I tested with this command:

 {{{
 %SHP2PGSQL% -c -s 4269:4326 -G -g geog  -W "latin1" tl_2010_42_zcta510
 tiger_staging.zcta510_42 > zip.sql
 }}}

 And it needs to cast the geometry first before transforming so I guess you
 need to make the same change for geography.

 Note:

 It produces


 {{{
 ST_Transform('gubblygook',4326)::geography
 }}}

 and needs to produce:


 {{{
 ST_Transform('gubblygook'::geometry,4326)::geography
 }}}

-- 
Ticket URL: <http://trac.osgeo.org/postgis/ticket/1759#comment:6>
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-devel mailing list