[postgis-devel] [PostGIS] #1152: SRID_MAXIMUM should be raised, gserialized_get/set_srid () should be patched and typemod int too

PostGIS trac at osgeo.org
Fri Aug 5 16:50:07 PDT 2011


#1152: SRID_MAXIMUM should be raised, gserialized_get/set_srid () should be
patched and typemod int too
----------------------+-----------------------------------------------------
  Reporter:  vince    |       Owner:  pramsey       
      Type:  defect   |      Status:  closed        
  Priority:  medium   |   Milestone:  PostGIS 2.0.0 
 Component:  postgis  |     Version:  trunk         
Resolution:  invalid  |    Keywords:  srid liblwgeom
----------------------+-----------------------------------------------------
Changes (by pramsey):

  * status:  new => closed
  * resolution:  => invalid


Comment:

 This is non-possible.

 The SRID_MAXIMUM is not a personal whim on my part, it is a hard limit
 imposed by moving to typmod geometries. The typmod mechanism only allows
 32 bits of typmod information (I did lobby for more at pgcon, but that's
 for the Future). Those 32 bits are allocated as follows

  * Plus/minus = Top bit.
  * Spare bits = Next 2 bits.
  * SRID = Next 21 bits.
  * TYPE = Next 6 bits.
  * ZM Flags = Bottom 2 bits.

 So, it can be a *little bit* larger, but not enough to address this
 ticket.

 Please note that external SRIDs of any size can be accommodated via the
 AUTH_SRID and AUTH_NAME facility, since the internal SRID is not
 necessarily supposed to map 1:1 to an external key (nor could it
 universally be expected to), so the entry for IGN would be
 {{{
 insert into spatial_ref_sys
 (srid, auth_name, auth_srid, srtext, proj4text)
 values
 (200000,'IGN', '310024140', 'something', 'something')
 }}}

-- 
Ticket URL: <http://trac.osgeo.org/postgis/ticket/1152#comment:4>
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