[Qgis-user] Transferring QGIS work when you used a PostGIS database

Rémi Cura remi.cura at gmail.com
Thu Mar 5 04:01:30 PST 2015


converting to spatialite may be a bad idea, because it won't work in all
cases (spatialite has less features than postgres/postgis).
(Im' thinking mat view, triggers, custom function, etc.)

The equivalent way, that is also the simplest, is to dump the tables (and
related functions/triggers if necessary) into a file, then restore the
table in the target postgis database!

For this you simply use the "pg_dump"
<http://www.postgresql.org/docs/current/static/app-pgdump.html> utility.
You have a graphical interface available in pgadmin.

This will create a flat text sql file (or compressed binary, depending on
the option).
You send this file via USB key or ftp or whatever, then

the person getting the dump file simply use
"pg_restore
<http://www.postgresql.org/docs/current/static/app-pgrestore.html>" on the
file

If you have few geom and all can be represented by shapefile, you have a great
plugin <http://plugins.qgis.org/plugins/qconsolidate/> that for all the
layers of your project create a shapefile, so that everything is easy to
send.

Cheers,
Rémi-C

2015-03-05 7:29 GMT+01:00 Alex Mandel <tech_dev at wildintellect.com>:

> On 03/04/2015 09:20 PM, Leahy, Thomas A. wrote:
> > Hello,
> >
> >    If I just use shape and raster files it is fairly easy for me to give
> someone all my QGIS work on a USB stick as it uses relative directory
> references as long as everything is below the Project Directory they can
> use it as I did. However if I decide to use PostGIS is there an easy way to
> similarly transfer the work that was done to another person?
> >
> >     Thanks for your assistance,
> >     Tom Leahy
>
> Convert the Postgis db to Spatialite. There are several tools out there
> for this, ogr2ogr would work, as would a couple of QGIS Plugins (offline
> editor can clone your postgis to local), the spatialite author even made
> some tool I can't recall the name right now.
>
> Eventually this will be the role of the new GeoPackage format that will
> bundle vector and raster into a sqlite db.
>
> Thanks,
> Alex
> _______________________________________________
> Qgis-user mailing list
> Qgis-user at lists.osgeo.org
> http://lists.osgeo.org/mailman/listinfo/qgis-user
>
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.osgeo.org/pipermail/qgis-user/attachments/20150305/7757e142/attachment.html>


More information about the Qgis-user mailing list