2

I have a shapefile of points in Qgis 2.18. I created the points by direct click on a map, using the digitizing tool. Now I need to fill the 2 columns "Lat" and "Long" in the attribute table with Geographic coordinates (DD MM.mmm).

The shapefile is in Utm. I used the instructions found here: How to automatically fill a lat/long in attribute table.

But when I try to use the Field calculator, the columns are filled with Lat and Long values referred to UTM. Even when I set the Project properties to Geographic, the Field calculator calculate always UTM coordinate to fill the columns.

  • 1
    Welcome to GIS SE! As a new user please take the tour to learn about our focused Question and Answer format. Please edit your question to include more information, such as what GIS software you're using, and what actual steps you've followed in your attempts. – Midavalo Jan 31 '17 at 17:38
  • Do you mean you need to transform to epsg 4326? Like I can use x(transform($geometry,'epsg:27700','epsg:4326')) to get the X coordinate for my UK Grid data? – Spacedman Jan 31 '17 at 22:02
  • Yes, my shapefile is in EPSG32632 and I need, in the table, the coordinates in EPSG 4326. Your script works (thanks!) but still I get DD.dddd while I need DD MM.mmm – David Feb 1 '17 at 9:31

Your Answer

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

Browse other questions tagged or ask your own question.