[postgis-devel] Testing on Windows PostGIS 1RC1

Paul Ramsey pramsey at opengeo.org
Wed Sep 22 16:34:23 PDT 2010


pramsey=# select isvalid('LINESTRING(1 2, 1 2)');
NOTICE:  Too few points in geometry component at or near point 1 2
 isvalid
---------
 f
(1 row)


On Wed, Sep 22, 2010 at 4:31 PM, Martin Davis <mbdavis at refractions.net> wrote:
>  I thought it might be worth pointing out that LINESTRING (1 2, 1 2) is not
> invalid according to the OGC SFS.  Is it considered invalid in PostGIS?
>
> On 9/22/2010 4:24 PM, strk wrote:
>>
>> On Thu, Sep 23, 2010 at 12:18:37AM +0200, Nicklas Avén wrote:
>>
>>> select st_snaptogrid('LINESTRING(1 2, 1 2)'::geometry, 0.1)
>>>
>>> So we don't get a parse error or an empty geometry, but... nothing
>>>
>>> Maybe empty geometry would be better?
>>
>> FWIW, that's an invalid geometry.
>> ST_MakeValid would make it a POINT.
>>
>> But yes, SnapToGrid turns collapsed geomeries into NULLs,
>> intentionally, as it was designed as a vector reduction tool.
>>
>> Dunno what would an empty give you more than the current NULL.
>> Possibly a POINT would help you more.
>>
>> --strk;
>>
>>   ()   Free GIS&  Flash consultant/developer
>>   /\   http://strk.keybit.net/services.html
>> _______________________________________________
>> postgis-devel mailing list
>> postgis-devel at postgis.refractions.net
>> http://postgis.refractions.net/mailman/listinfo/postgis-devel
>>
>
> --
> Martin Davis
> Senior Technical Architect
> Refractions Research, Inc.
> (250) 383-3022
>
> _______________________________________________
> postgis-devel mailing list
> postgis-devel at postgis.refractions.net
> http://postgis.refractions.net/mailman/listinfo/postgis-devel
>



More information about the postgis-devel mailing list