<html><head><meta http-equiv="Content-Type" content="text/html charset=utf-8"></head><body style="word-wrap: break-word; -webkit-nbsp-mode: space; -webkit-line-break: after-white-space;" class=""><div class=""></div><div class=""><div class="">see anything wrong? Let me know.</div><div class=""><br class=""></div><div class="">greetings,</div><div class=""><br class=""></div><div class="">Joris</div><div class=""><br class=""></div><div class=""><br class=""></div></div><div class="">
        
        
        
        



<br class=""><div class=""><br class=""></div><div class=""><br class=""></div><br class=""><div><blockquote type="cite" class=""><div class="">Op 7 jan. 2016, om 03:08 heeft Nathan Woodrow <<a href="mailto:madmanwoo@gmail.com" class="">madmanwoo@gmail.com</a>> het volgende geschreven:</div><br class="Apple-interchange-newline"><div class=""><p dir="ltr" class="">Or use excel to make a WKT column and import that.</p><p dir="ltr" class="">Nathan</p>
<br class=""><div class="gmail_quote"><div dir="ltr" class="">On Thu, 7 Jan 2016 11:48 am Nyall Dawson <<a href="mailto:nyall.dawson@gmail.com" class="">nyall.dawson@gmail.com</a>> wrote:<br class=""></div><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex">On 7 January 2016 at 07:08, Joris Hintjens <<a href="mailto:jorishin@gmail.com" target="_blank" class="">jorishin@gmail.com</a>> wrote:<br class="">
> Hello,<br class="">
> I’m lost.<br class="">
> I have a list of movements. A table with (among others) a column “FROM”  and a column “TO” (both containing coordinates)<br class="">
><br class="">
> How can I import this in QGIS so that I have a bunch of lines going from FROM to TO?<br class="">
><br class="">
<br class="">
This is relatively straightforward in QGIS master:<br class="">
<br class="">
- import your CSV file<br class="">
- right click the CSV layer, and choose "Save as"<br class="">
- change format to "ESRI Shapefile". Choose the correct CRS for your<br class="">
coordinates.<br class="">
- expand out the "Geometry" group and change "Geometry type" from<br class="">
"Automatic" to "LineString"<br class="">
- click OK, the new LineString shapefile (with all null geometries)<br class="">
will be added to the project<br class="">
- now, you need to create the geometries. This is done through the<br class="">
field calculator.<br class="">
- tick "update existing field"<br class="">
- change the field to "<geometry>"<br class="">
- enter the expression:<br class="">
'make_line(make_point("x1","y1"),make_point("x2","y2"))' (but replace<br class="">
x1, y1, ... with the correct columns names from your original CSV<br class="">
file)<br class="">
- click OK. Done!<br class="">
<br class="">
Nyall<br class="">
<br class="">
<br class="">
> thanks for your comments<br class="">
><br class="">
> Joris<br class="">
><br class="">
> _______________________________________________<br class="">
> Qgis-user mailing list<br class="">
> <a href="mailto:Qgis-user@lists.osgeo.org" target="_blank" class="">Qgis-user@lists.osgeo.org</a><br class="">
> List info: <a href="http://lists.osgeo.org/mailman/listinfo/qgis-user" rel="noreferrer" target="_blank" class="">http://lists.osgeo.org/mailman/listinfo/qgis-user</a><br class="">
> Unsubscribe: <a href="http://lists.osgeo.org/mailman/listinfo/qgis-user" rel="noreferrer" target="_blank" class="">http://lists.osgeo.org/mailman/listinfo/qgis-user</a><br class="">
_______________________________________________<br class="">
Qgis-user mailing list<br class="">
<a href="mailto:Qgis-user@lists.osgeo.org" target="_blank" class="">Qgis-user@lists.osgeo.org</a><br class="">
List info: <a href="http://lists.osgeo.org/mailman/listinfo/qgis-user" rel="noreferrer" target="_blank" class="">http://lists.osgeo.org/mailman/listinfo/qgis-user</a><br class="">
Unsubscribe: <a href="http://lists.osgeo.org/mailman/listinfo/qgis-user" rel="noreferrer" target="_blank" class="">http://lists.osgeo.org/mailman/listinfo/qgis-user</a></blockquote></div>
</div></blockquote></div><br class=""></div></body></html>