I am trying to link a CSV to a shapefile using the method as described in this tutorial: http://maps.cga.harvard.edu/qgis/wkshop/join_csv.php

It seems to work fine but the problem is that the CSV when imported in QGIS reads all data as strings. I found a suggestion online to save another file as csvt. In the same location (see Changing CSV layer attribute value from text to number in QGIS?) and I tried using “text wrangler” and “text edit” but it didn't work out.

Can anyone suggest a solution that works on a MAC (QGIS: 2.4.0-Chugiak)?

  • Awesome, glad it works Pama! I will post the comment as an answer for the convenience of others. – Joseph Oct 21 '14 at 14:22

You can use the Field Calculator to create a new column and then use a similar command like the following in the expression:

toreal("your column") 

for real numbers.

toint("your column") 

for integers.

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.