I´m trying to recover a previous version of a Qgis file, because I started playing around with CRS, and saved the file and closed it, thinking next time it woud be easy to get everything back into place.. BUT now all my layers are flying around all over the place and I can´t get them back to matching one on top of the other even when they apparently ahve the same CRS and projection (I´ve been trying to for hours, apparently there´s something seriously wrong with native projections.. but I did have them neatly lined up, so I don´t know what happened) So, I think the easiest would be to go back to last night´s version of the file. Except, when I right click the file and hit restore previous version, there are no previous versions to choose from... any ideas? I´m running Qgis Essen on Windows Parallels (I´m on Mac Yosemite OS).

  • P.S. I found a .qgis~ file that looks like back up, I can open it in wordpad, but don´t know how to translate it back into qgis! – semilla May 29 '16 at 19:51
  • 3
    Just rename the file and remove the ~ at the end of .qgis ~. It is a backup file. – Pierma May 29 '16 at 21:49

QGIS stores the data in several places:

  • the data of every vector and raster layer is stored in the file(s) according to the format you have chosen (shapefile, spatialite, Geotiff etc)
  • Web services might be cached locally, otherwise only the connection parameters are stored
  • all layer and styling information is stored in a .qgs project file, and backed up in a .qgis~ file until the next save operation

So it depends on the steps you did where the changes were stored. CRS information is stored in vector/raster files as well as the project file.

For shapefiles, QGIS stores the projection information also in a .qpj file which is not used by any other software. You have to delete that if you reload the data from external sources. Otherwise, you have to use Set Layer CRS to assign back the right projection.

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.