[prev in list] [next in list] [prev in thread] [next in thread] 

List:       postgis-users
Subject:    [postgis-users] st_intersection error/bug?
From:       Düster_Horst <Horst.Duester () bd ! so ! ch>
Date:       2009-08-28 10:39:20
Message-ID: H00002eb0568c9e3.1251455959.srsofaioi6145.ktso.ch () MHS
[Download RAW message or body]

[Attachment #2 (multipart/alternative)]


I do have 2 simple linestrings which partly have the same geometry (see
attached dump and image). My aim is to detect the common part of these
two linestrings with the following query:

select st_intersection(a.the_geom, b.the_geom), a.myid
from aline1, aline2

But as the result I get a geometrycollection with one POINT and one
LINESTING. I expected one linestring. Is it a bug??
I'll appreciate any hints.

My system:
Postgis 1.4.0
Geos 3.1.1
Postgres 8.3.6

Best regards
   
Dr. Horst Düster
Stv. Amtschef / GIS-Koordinator 

Kanton Solothurn
Bau- und Justizdepartement
Amt für Geoinformation
SO!GIS Koordination
Rötistrasse 4
CH-4501 Solothurn

Telefon ++41(0)32 627 25 32
Telefax ++41(0)32 627 22 14

mailto:horst.duester@bd.so.ch
http://www.agi.so.ch



[Attachment #5 (text/html)]

<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.0 Transitional//EN">
<html lang="en">
<head><meta http-equiv="Content-Type" content="text/html;">
<title>Scalix message content</title>
<style type="text/css">
<!--
.Normal {  text-align: left; text-indent:0pt; margin-top:0pt; margin-bottom:0pt; \
                font-family: Arial; font-size: 12pt; }
.Default_Paragraph_Font {font-family: Arial; color: Black; background-color: white ; \
font-size: 12pt; font-weight: normal;  font-style: normal; font-variant: normal; \
vertical-align: normal; text-decoration: none;} div.ltTOCtitle { font-family: \
Verdana; font-size: 8pt; font-weight: bold; text-align: center;} div.ltTOCl1 { \
font-family: Verdana; font-size: 8pt; font-weight: bold; margin-left:32pt; \
text-indent:-32pt;} div.ltTOCl2 { font-family: Verdana; font-size: 8pt; font-weight: \
bold; margin-left:40pt; text-indent:-32pt;} div.ltTOCl3 {  font-family: Verdana; \
font-size: 8pt; font-weight: bold; margin-left:48pt; text-indent:-32pt;} div.ltTOCl4 \
{ font-family: Verdana; font-size: 8pt; font-weight: bold; margin-left:56pt; \
text-indent:-32pt;} div.ltTOCl5 { font-family: Verdana; font-size: 8pt; font-weight: \
bold; margin-left:64pt; text-indent:-32pt;} div.ltTOCl6 { font-family: Verdana; \
                font-size: 8pt; font-weight: bold; margin-left:72pt; \
                text-indent:-32pt;}
-->
</style>
</head>

<body>
<div class="Normal"><span style='font-size: 10pt; '>I do have 2 simple
linestrings which partly have the same geometry (see attached dump and image).
My aim is to detect the common part of these two linestrings with the following
query:</span></div>
<br>
<div class="Normal"><span style='font-size: 10pt; '>select
st_intersection(a.the_geom, b.the_geom),
a.myid</span><br><span style='font-size: 10pt; '>from aline1,
aline2</span></div>
<br>
<div class="Normal"><span style='font-size: 10pt; '>But as the result I get a
geometrycollection with one POINT and one LINESTING. I expected one linestring.
Is it a bug??</span><br><span style='font-size: 10pt; '>I'll appreciate any
hints.</span></div>
<br>
<div class="Normal"><span style='font-size: 10pt; '>My
system:</span><br><span style='font-size: 10pt; '>Postgis
1.4.0</span><br><span style='font-size: 10pt; '>Geos
3.1.1</span><br><span style='font-size: 10pt; '>Postgres 8.3.6</span></div>
<br>
<div class="Normal"><span style='font-size: 10pt; '>Best regards</span></div>
<br>
<div class="Normal"><span style='font-size: 10pt; '>Dr. Horst
D&uuml;ster</span><br><span style='font-size: 10pt; '>Stv. Amtschef /
GIS-Koordinator </span></div>
<br>
<div class="Normal"><span style='font-size: 10pt; '>Kanton
Solothurn</span><br><span style='font-size: 10pt; '>Bau- und
Justizdepartement</span><br><span style='font-size: 10pt; '>Amt f&uuml;r
Geoinformation</span><br><span style='font-size: 10pt; '>SO!GIS
Koordination</span><br><span style='font-size: 10pt; '>R&ouml;tistrasse
4</span><br><span style='font-size: 10pt; '>CH-4501 Solothurn</span></div>
<br>
<div class="Normal"><span style='font-size: 10pt; '>Telefon ++41(0)32 627 25
32</span><br><span style='font-size: 10pt; '>Telefax ++41(0)32 627 22
14</span></div>
<br>
<div class="Normal"><span style='font-size: 10pt; \
'>mailto:horst.duester@bd.so.ch</span><br><span style='font-size: 10pt; \
'>http://www.agi.so.ch</span></div> <br>



</body>

</html>


["aline1.sql" (application/octet-stream)]
["aline2.sql" (application/octet-stream)]
["intersecterror.png" (application/octet-stream)]

_______________________________________________
postgis-users mailing list
postgis-users@postgis.refractions.net
http://postgis.refractions.net/mailman/listinfo/postgis-users


[prev in list] [next in list] [prev in thread] [next in thread] 

Configure | About | News | Add a list | Sponsored by KoreLogic