[postgis-users] error in extent command

Paul Ramsey pramsey at refractions.net
Mon May 21 07:30:05 PDT 2007


Wrap your extent() in a setsrid() function (or drop your srid  
constraint).
This points up what I think is a bug (or at least bad behavior) in  
that the output of extent should reflect the srid of the geometries  
that go into it.

On 21-May-07, at 1:16 PM, temiz wrote:

> I created spatial db as:
>
> bzk2=# select addgeometrycolumn('exp1','geom',32767,'GEOMETRY',2);
>
> then I wanted to insert  this value to spatial db. But I received  
> this message:
>
> update exp1 set geom=(select extent(wkb_geometry) from shey6  where  
> shey6.cat=2);
> ERROR:  new row for relation "exp1" violates check constraint  
> "enforce_srid_geom"
>
> what can I do ?
>
> regards
>
>
> -- 
> This message has been scanned for viruses and
> dangerous content by MailScanner, and is
> believed to be clean.
>
> _______________________________________________
> postgis-users mailing list
> postgis-users at postgis.refractions.net
> http://postgis.refractions.net/mailman/listinfo/postgis-users




More information about the postgis-users mailing list