I am writing a tutorial for MSc students that uses QGIS. One of the tasks requires the attribute data to be modified (see pdf draft of tutorial here if interested ).
The question is how to get them to edit the attribute data. I know this question has been asked before, and the answer used to be simple: just use LibreOffice calc to modify it and then save it, ensuring the row order and column titles are kept the same. I have used this approach before to great effect.
Unfortunately, the solution no longer works: saving the .dbf file, in LibreOffice (5.4.2) or OpenOffice (3.4.1) Calc scrambles the data from the perspective of QGIS (only random integer numbers appear in the attribute table), and creates an additional .dbt file instead.
So to get to the question: how do I tell a class of MSc students to do this next week? I've considered the following options:
- Use R instead (great for me, but scary for students)
- Edit the file as a .csv, and then join based on timestamp (fine, but seems overly complex, and could introduce more error in the 2 hour practical)
- Use an alternative program: I've tried Gnumeric and Excel, neither of which generated good results quickly.
To help answer this question, I've created a replicable example. Open the file "points.shp" in QGIS, observer the attribute table then close. Edit a couple of cells in the attribute table "points.dbf" in LibreOffice - save. Re-open "points.shp" in QGIS and observe the scrambled attribute table. The other shapefiles in the .zip folder have already been corrupted by LibreOffice and OpenOffice to illustrate what the problem looks like for me.
In short, how do I best solve this problem?