[postgis-tickets] [PostGIS] #3009: ST_Area(the_geom, false) and other geography functions may change column value
PostGIS
trac at osgeo.org
Wed Dec 17 07:15:33 PST 2014
#3009: ST_Area(the_geom, false) and other geography functions may change column
value
---------------------+------------------------------------------------------
Reporter: fursten | Owner: pramsey
Type: defect | Status: new
Priority: blocker | Milestone: PostGIS 2.1.5
Component: postgis | Version: 2.1.x
Keywords: |
---------------------+------------------------------------------------------
Comment(by robe):
okay yap its at our caster watch this:
{{{DROP TABLE IF EXISTS test_weird;
CREATE TABLE test_weird AS SELECT 'MULTIPOLYGON(((-8.62650874577284
115.346832275391,-8.58441599597068 115.309066772461,-8.68013625652618
115.214309692383,-8.72629051135205 115.198516845703,-8.76225972524743
115.307693481445,-8.64348030291466 115.343399047852,-8.62650874577284
115.346832275391)))'::geometry As areas;
SELECT ST_AsText(areas)
FROM test_weird;
-- outputs --
MULTIPOLYGON(((-8.62650874577284 115.346832275391,-8.58441599597068
115.309066772461,-8.68013625652618 115.214309692383,-8.72629051135205
115.198516845703,-8.76225972524743 115.307693481445,-8.64348030291466
115.343399047852,-8.62650874577284 115.346832275391)))
-- now for the eh magic --
SELECT areas::geography
from test_weird;
-- followed by --
SELECT ST_Astext(areas)
from test_weird;
-- yikes
MULTIPOLYGON(((-8.62650874577284 64.653167724609,-8.58441599597068
64.690933227539,-8.68013625652618 64.785690307617,-8.72629051135205
64.801483154297,-8.76225972524743 64.692306518555,-8.64348030291466
64.656600952148,-8.62650874577284 64.653167724609)))
}}}
--
Ticket URL: <http://trac.osgeo.org/postgis/ticket/3009#comment:7>
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-tickets
mailing list