[postgis-users] point to multipoint

Suhr, Ralf Ralf.Suhr at itc-halle.de
Thu Nov 26 00:19:27 PST 2009


Use ST_Multi(point) to get what you want.

You can build your query using  ST_DWithin(geomA, geomB, dist).

 

Gr Ralf

Von: postgis-users-bounces at postgis.refractions.net [mailto:postgis-users-bounces at postgis.refractions.net] Im Auftrag von Mehmet Sirin
Gesendet: Donnerstag, 26. November 2009 01:52
An: PostGIS Users Discussion
Betreff: [postgis-users] point to multipoint

 

hi, is someone out there who can explain how to make several points to a multipoint.. i tried st_union and st_collect but what comes out is a multilinestring and geometrycollection(string(..)) respectively.

code with which the unwilling multilinestring happens:

select astext(st_union(c.geom_4326)) from (
    select * from (select * from(
        select *,buffer(geom_4326,0.01)as buff from gc_berechnet where name='Neuer Graben' and                
        gemeinde='Osnabrück')a)b, zip_coordinates zc
where contains(buff,zc.geom) )c


what i want to do: 
1.buffering a pointt (A) with a radius of 1km
2.take a look which other points lie in this buffer polygon
3.find out which point inside the buffer is nearest to the first point (A) i buffered.
important for 3. : when having a multipoint i can easily use st_distance to determine the closest point to point (A)


you can tell me how to create multipoint ? then i love you^^



leaving you kind regards
mehmet sirin c.

-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.osgeo.org/pipermail/postgis-users/attachments/20091126/e72bc447/attachment.html>


More information about the postgis-users mailing list