Two version of a dataset #779
-
I have two versions of a dataset. Let's say d_v1.gpkg and d_v2.gpkg. Now I created a kart repo with kart init dtt --import GPKG:d_v1.gpkg. Now I would like to add d_v2.gpkg to the same source. How do I do that with kart? |
Beta Was this translation helpful? Give feedback.
Replies: 2 comments
-
You can use Note that for this to work properly, you really want a consistent primary key across your import sources. Kart tries to auto-detect this (eg: GeoPackage mandates you have a primary key), but you can also manually specify it via |
Beta Was this translation helpful? Give feedback.
-
Okay, that's great, thanks! |
Beta Was this translation helpful? Give feedback.
You can use
kart import --replace-existing
— this will load ind_v2.gpkg
as a new revision of the same dataset, but identical records from the existing data get (effectively) matched sokart log
/kart diff
etc will only show the differences.Note that for this to work properly, you really want a consistent primary key across your import sources. Kart tries to auto-detect this (eg: GeoPackage mandates you have a primary key), but you can also manually specify it via
--primary-key
.