<html><body><div style="color:#000; background-color:#fff; font-family:times new roman, new york, times, serif;font-size:12pt"><div>Hello,</div><div>I have a question about snapping a huge number of linestrings such that all lines that are almost parallel and within 50m collapse into one.<br><br>I have some 500,000 streets from Openstreetmap (classified as secondary or larger roads). Most of them are made of two or more lanes. For a more compact storage and faster rendering I need only a visual representation of each road. How can I collapse for example the 6 lanes of a motorway into one linestring?<br><br>Do I have to run a loop over all roads, snapping each of them to all others within the given tolerance? This seems extremely slow. Or can it be done once for all geometries? <br>Do you have some SQL examples for a similar processing step?<br><br>Thanks<br>Greg</div></div></body></html>