<html><body><div style="color:#000; background-color:#fff; font-family:arial, helvetica, sans-serif;font-size:10pt"><div><span>You're looking at some custom stuff.</span></div><div><span><br></span></div><div>But, I'd do something a long these lines:</div><div>- Load the data into PostgreSQL (hey, I have no systems restrictions, so I'm going to suggest it how *I'd* do it. :D )</div><div>- Read the point as a service, that's easy enough (look at identify.py) as an example.</div><div>- Run some SQL to find the nearest line to the point clicked (I'm assuming the data is stored in ground units, like meters...)</div><div><br></div><div>select line_id from water_lines where st_distance(geomfromtext($1, water_lines.wkb_geometry )) < 3</div><div><br></div><div>- Then use that line_id to find all the attached valves...</div><div><br></div><div>select valve_id, wkb_geometry from water_line_valves where line_id = $1</div><div><br></div><div>- Or, if I didn't
find any ON the line with an ID... this will find all valves within 5 meters (assuming units of meters) of the water line.</div><div><br></div><div>select valve_id, valves.wkb_geometry</div><div>from water_lines, water_line_valves valves</div><div>where st_distance(water_lines.wkb_geometry, valves.wkb_geometry) < 5</div><div>and water_line.line_id = $1</div><div><br></div><div>Then do some magic to report more info on the valves, and ship down an extent made up of those points.</div><div><br><blockquote style="border-left: 2px solid rgb(16, 16, 255); margin-left: 5px; padding-left: 5px;"><div style="font-size: 10pt; font-family: arial, helvetica, sans-serif; "><div style="font-size: 12pt; font-family: 'times new roman', 'new york', times, serif; "><font size="2" face="Arial"><hr size="1"><b><span style="font-weight:bold;">From:</span></b> Ed Boesenberg <eboesenberg@niraengineers.com><br><b><span style="font-weight: bold;">To:</span></b>
geomoose-users@lists.osgeo.org<br><b><span style="font-weight: bold;">Sent:</span></b> Tuesday, November 1, 2011 1:47 PM<br><b><span style="font-weight: bold;">Subject:</span></b> [Geomoose-users] Isolate Water System Valve for Waterline Break<br></font><br>
<div id="yiv840436896"><style><!--
#yiv840436896
_filtered #yiv840436896 {font-family:"Cambria Math";panose-1:2 4 5 3 5 4 6 3 2 4;}
_filtered #yiv840436896 {font-family:Calibri;panose-1:2 15 5 2 2 2 4 3 2 4;}
#yiv840436896
#yiv840436896 p.yiv840436896MsoNormal, #yiv840436896 li.yiv840436896MsoNormal, #yiv840436896 div.yiv840436896MsoNormal
        {margin:0in;margin-bottom:.0001pt;font-size:11.0pt;font-family:"sans-serif";}
#yiv840436896 a:link, #yiv840436896 span.yiv840436896MsoHyperlink
        {color:blue;text-decoration:underline;}
#yiv840436896 a:visited, #yiv840436896 span.yiv840436896MsoHyperlinkFollowed
        {color:purple;text-decoration:underline;}
#yiv840436896 span.yiv840436896EmailStyle17
        {font-family:"sans-serif";color:windowtext;}
#yiv840436896 .yiv840436896MsoChpDefault
        {}
_filtered #yiv840436896 {margin:1.0in 1.0in 1.0in 1.0in;}
#yiv840436896 div.yiv840436896WordSection1
        {}
--></style><div><div class="yiv840436896WordSection1"><div class="yiv840436896MsoNormal">Would it be possible to create a GeoMoose service in which the user would click a point on a polyline (waterline), the point would represent a waterline break, and the service would search for valves along the waterline to determine which valves to shutoff to isolate the break then zoom to selected valves? All of my data is in shapefiles.</div><div class="yiv840436896MsoNormal"> </div><div class="yiv840436896MsoNormal">If it is possible, what would be the sections of code I would start to modify or create?</div><div class="yiv840436896MsoNormal"> </div><div class="yiv840436896MsoNormal">Ed Boesenberg</div></div></div></div><br>_______________________________________________<br>Geomoose-users mailing list<br><a ymailto="mailto:Geomoose-users@lists.osgeo.org" href="mailto:Geomoose-users@lists.osgeo.org">Geomoose-users@lists.osgeo.org</a><br><a
href="http://lists.osgeo.org/mailman/listinfo/geomoose-users" target="_blank">http://lists.osgeo.org/mailman/listinfo/geomoose-users</a><br><br><br></div></div></blockquote></div></div></body></html>