[postgis-devel] [PostGIS] #1594: AddGeometryColumns has a problem with certain SRID's

PostGIS trac at osgeo.org
Tue Feb 21 06:46:51 PST 2012


#1594: AddGeometryColumns has a problem with certain SRID's
---------------------+------------------------------------------------------
 Reporter:  soi      |       Owner:  pramsey      
     Type:  defect   |      Status:  new          
 Priority:  low      |   Milestone:  PostGIS 2.0.0
Component:  postgis  |     Version:  1.5.X        
 Keywords:           |  
---------------------+------------------------------------------------------
 AddGeometryColumns() reports lots of given SRID's (all i tested it with
 except -1) as invalid but at the same time it is possible to change the
 SRID with UpdateGeometrySRID(). Corrensponding logs follow.

 2012-02-20 14:52:27 CET LOG:  statement: CREATE TABLE "shape_basin" (gid
 serial PRIMARY KEY,
         "sampleid" varchar(50),
         "area" float8);
 2012-02-20 14:52:46 CET LOG:  statement: SELECT
 AddGeometryColumn('','shape_basin','the_geom',4326,'MULTIPOLYGON',2);
 2012-02-20 14:52:46 CET ERROR:  AddGeometryColumns() - invalid SRID

 However this is possible:

 2012-02-20 14:55:21 CET LOG:  statement: SELECT
 AddGeometryColumn('','shape_basin','the_geom',-1,'MULTIPOLYGON',2);
 2012-02-20 14:55:57 CET LOG:  statement: SELECT
 UpdateGeometrySRID('shape_basin', 'the_geom', 4326);

-- 
Ticket URL: <http://trac.osgeo.org/postgis/ticket/1594>
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