Geographic Information Systems Stack Exchange is a question and answer site for cartographers, geographers and GIS professionals. Join them; it only takes a minute:

Sign up
Here's how it works:
  1. Anybody can ask a question
  2. Anybody can answer
  3. The best answers are voted up and rise to the top

I have now successfully got OSM maps to import as I would like, but if I save the project then later re-open, I always get a bad layer message and I have to reload the OSM once the project is open.

How can I save the datasource reference with the project so I don't get this every time?

share|improve this question
Is this problem one that arises when you import OSM data from an *.osm file using the OpenStreetMap plug-in? – nhopton Aug 2 '12 at 7:52
up vote 1 down vote accepted

You can save the imported data into a spatialite database, and add the spatialite layers to your project. Then you can delete the Openstreetmap layer from your project.

Openstreetmap data comes in a special format, and has to be "translated" to GIS standards. By saving to a spatial database you only have to do that once.

share|improve this answer
Is there a way to do it without importing into a database? If not, can you point me in the direction of a 'how to' for this process. I have MS SQL 2008. – Peter Cornelissen Aug 1 '12 at 23:08
You can also use ESRi shapefilles. Just right-click the layer and save as. I have no experience with MS SQL2008. Spatialite support is built-in with Qgis. Create new Spatialite layers for points, lines and polygons, make them editable, and copy and paste the data from existing layers to the new ones. If your project area is country-wide, the best solution is a PostgreSQL database with Postgis extension. Openstreetmap has a good importer for that called osm2pgsql. You find help for that in OSM wiki. Quantum GIS can query that Postgis database easily. – AndreJ Aug 2 '12 at 5:38
That's great, using ESRi shapefiles is just what I wanted to know. I don't really need to use a database as the area I am working with is quite small (about 100km2). – Peter Cornelissen Aug 2 '12 at 19:54

Your Answer


By posting your answer, you agree to the privacy policy and terms of service.

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