[postgis-users] Transformation

Thomas Zuberbuehler tzuberbuehler at datacomm.ch
Mon Dec 11 06:05:32 PST 2006


Hi

Thank you for your answer!
I found a solution in the meantime.

UPDATE BaseGeometrySHP SET the_geom = transform(force_2d(the_geom), 4326);

This would be work.

Regards,
Thomas


2006/12/11, Obe, Regina <robe.dnd at cityofboston.gov>:
> It sounds like your the_geom field has a  check contraint on it for a
> different SRID other than 4326.  Did you use addgeometry to build the
> the_geom field and did you specify 4326 as the SRID when you did that?
>
> I'm guessing that constraint was put in manually since the name that the
> addgeometry function assigns would be usually enforce_srid_the_geom
> unless a constraint with that name already existed for that table.
>
> -----Original Message-----
> From: postgis-users-bounces at postgis.refractions.net
> [mailto:postgis-users-bounces at postgis.refractions.net] On Behalf Of
> Thomas Zuberbuehler
> Sent: Monday, December 11, 2006 6:54 AM
> To: PostGIS Users Discussion
> Subject: [postgis-users] Transformation
>
> Hi
>
> I have a problem. Following SQL Statement don't work, why?
>
> UPDATE HikeRoute SET the_geom =
> GetFromastext(Transform(SetSRID(force_2d(the_geom), 21781), 4326));
>
> ERROR:  new row for relation "hikeroute" violates check constraint
> "enforce_srid_the_geom1"
>
> Who has a solution how I can do this?
>
> Thank you.
> Regards,
> Thomas
>
> --
> Thomas Zuberbuehler
> http://www.zubi.li
> _______________________________________________
> postgis-users mailing list
> postgis-users at postgis.refractions.net
> http://postgis.refractions.net/mailman/listinfo/postgis-users
>
> -----------------------------------------
> The substance of this message, including any attachments, may be
> confidential, legally
> privileged and/or exempt from disclosure pursuant to Massachusetts
> law. It is intended
> solely for the addressee. If you received this in error, please
> contact the sender and
> delete the material from any computer.
>
> _______________________________________________
> postgis-users mailing list
> postgis-users at postgis.refractions.net
> http://postgis.refractions.net/mailman/listinfo/postgis-users
>


-- 
Thomas Zuberbuehler
http://www.zubi.li



More information about the postgis-users mailing list