Gramps vs. PostGIS vs. SpatialLite

This is most of all a question or an idea for future features…

Could Gramps benefit from PostGIS for PostgreSQL or SpatialLite for sqlite rwhen it comes to geospatial data?
Maybe as some kind of “companion database function”?

With those solutions people could actually download and import national historical geospatial databases that could be used in Gramps…

Just as two examples, I know that both Norway and Sweden have some geospatial databases with historical data, historical names, etc.
I have also seen a few Universities around that have made some geospatial databases with historical data… and most of those data is actually Open Source and Open Data.

And Yes, those datasets had to be downloaded manually outside of Gramps, because they can be multiple terabytes in size…

Maybe a feature to enable it as an extra feature in Gramps, with an easy one button “import geospatial data from file” or just a wiki instruction on how to import that type of data via a Windows, MAC or Linux cmd line/prompt?

1 Like

This is interesting.

You idea popped as I was wondering whether to add the Home Place designation to GEPS 043: Improving GEDCOM support for Places.

And noticed that while there is a proposal to add a UUID data element to the Gramps People model, there isn’t a similar UUID extension for the Place or Citation model. However, the existence of a UUID for People seems like a 1st step towards a harmonization/merge engine for Gramps.

I’ve begun using the GeoNames (wiki: Geonames; addon: GeoName, PlaceCleanup, GetGov)

PlaceCleanup highjacks the Gramps PlaceID as a UUID. That is OK if I will only use the GeoNames gazetteer. But what happens if someone writes a plugin that leverages features an external database like PostGIS or SpatiaLite in the future? And such plugins might scrape data into Gramps (like PlaceCleanup) or become more sophisticated (like @StoltHD suggests) and poll for live updates.

So how about UUIDs for the Core Objects in Gramps? Hopefully with more than a Name and Value tuple.

Other Gazatteers

Most Gazetteer data that include geospatial data can be imported into any of these solutions as long as the data is CSV or JSON, just like how most geospatial data from cartography agencies store them.

I have actually imported the whole geonames csv file into Gramps via the CSV import (reduced columns of course).

I did actually create the Gramps CSV for hierarchy place data in Excel with a query against 2 separate workbooks… That was back when I recommended using OpenRefine to clean up place data… 5-6 years ago, or something… before this forum.

I should add that that is not a good idea as Gramps query data today…

Even my geonames file for Norwegian places (some 300k place names), took a really long time to import and even longer to open in the Place View…

And back then it was also the problem with the CSV import crashing when the data in the CSV was not in the correct order, and all the problems with overwritten place names etc.

Edit: just needed to change some grammars and lost words

A UID and EXID tag are included in the IDENTIFIER_STRUCTURE in the Gedcom 7.0 specification.

For an identifier maintained by an external authority you would use EXID. For example:

2 EXID object_388462