Tracking, calculating and merging vector changes with Input and QGIS

NOVEMBER 23, 2019 input mergin qgis

The latest beta release of Input (v.0.4.90) comes with smart diff support for vectors. This will allow you to use the app (current beta version) in a collaborative environment, where several users can make changes to a single survey layer (geopackage).

What does it mean?

It is often the case, where multiple users need to make changes to a single vector layer. If you work in office, this issue is usually addressed by having a central geodatabase (e.g. Postgres/PostGIS). If you want extra information (e.g. audit trails, versioning, latest changes, etc), you can modify your database, to keep track of it.

The problem arises when you want to collect data, without having access to the central geodatabase. You can do some manual work to handle this scenario, but it can easily lead into data management nightmare.

To simplify the workflow, we have developed Geodiff, a multi-platform library to keep track of changes, calculate the differences, merge and consolidate the differences.

How can I use it?

Geodiff has been integrated into the beta version of Input. This will allow you to share a project with your team and edit a single layer (geopackage format) all at the same time, even when you are offline.

To start with, you need to create a project and upload it to Mergin. You can then share the project (with write access) with your colleagues:

Sharing projects through Mergin

The project contains a survey layer (trees.gpkg). There is only one feature present within the layer:

Sharing projects through Mergin

The project is shared with two users. Both users download the project and take their devices to the field:

User 1, carried out a survey (using iPhone!), by adding a tree and editing the attribute table of the existing one. The changes were synchronised back through the Mergin:

Meanwhile, User 2 added a new feature to the survey layer. Once User 2 tries to synchronise the changes, Input automatically detects the changes not only made through User 2, but also the ones uploaded to the Mergin. The layer will be patched both locally and on the server to take all the changes into account:

The data administrator can now pull all the changes from both users in QGIS:

You can also see the history of changes to the project and the survey layer on the Mergin website. Below shows the changes from different users:

Sharing projects through Mergin

To see changes from each user, you can click on the version and it lists the changes. In this example, User 1 (jack) added a new feature and modified an existing feature:

Sharing projects through Mergin

You can also see the extended history and see where the changes have been made:

Sharing projects through Mergin

How can I test this new feature?

You can use Beta version of Input app in Android or TestFlight in iOS:

Get it on Google Play Get it on App Store

For any issues or feedback, please file a ticket on Input repository


Posted by Saber Razmjooei