[Qgis-user] Using templates in QGIS when importing GPS-data to PostGIS

Pekka Hurskainen pekka.hurskainen at gmail.com
Mon Jul 4 01:29:31 PDT 2011


Hello list,

Let's say I have a bunch of waypoints collected with a GPS device, and
uploaded to QGIS with GPSBabel in GPX-format. I have only four fields
in the GPX file which I want to keep (lat, lon, time, name).

Then I have an empty template shapefile, which has more fields
defined. Some of them has to be filled interactively in QGIS, some of
them will be filled by trigger functions in PostGIS. The point is that
the template shapefile has to match exactly the table definitions in
my PostGIS database, so that it is possible to append GPS datasets to
the database using PostGIS Manager plugin. I can't just spit the GPX
files straight to PostGIS.

The problem is how to "combine" the GPX points with the template. I've
tried to merge these two with fTools and mmqgis plugins, but these
both add all fields from both layers, which I don't want (there isn't
an option to choose fields). Also I haven't found any "append" tool
similar to ArcGIS in QGIS.

I know it's possible to overcome this with manually deleting the
unwanted fields, but I want to automate the process since this part
will be repeated hundreds of times.

Any ideas?


Pekka Hurskainen



More information about the Qgis-user mailing list