0

I am creating a tree survey system in QGIS. There will be three geometry layers (called 'Single Trees', 'Line of Trees & Hedges', 'Groups of Trees') and each of those layers has a 'TreeUUID' field that generates a UUID automatically.

I want to be able to link features on these layers to another layer ('stems') so that a feature one of the first 3 layers can potentially have multiple entries into 'stems'.

My attempt was to create a polymorphic relationship like this: Polymorphic attempt 1

However I cannot then create the relation reference field on the 'stems' layer: stems form

It looks to me like it should work. I can create a child feature on 'stems' from the main 3 layers but they do not link properly once created. I am unsure exactly what I am missing and there seems to be relatively little information available about polymorphic relationships in QGIS. Does anyone have any ideas?

3
  • 1
    This could help : opengis.ch/2022/11/29/…
    – J.R
    Dec 1, 2022 at 16:12
  • I had looked through that but there isn't really anything specific to polymorphic relationships. I am wondering if I just have to use a series of 1-n relations from my main layers to the 'stems' layer.
    – Nathan
    Dec 1, 2022 at 16:21
  • They use a polymorphic relation with the "Document Management System Widgets" as I have not used it I can't say if it will work with "non document feature"...
    – J.R
    Dec 1, 2022 at 16:43

0

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge that you have read and understand our privacy policy and code of conduct.

Browse other questions tagged or ask your own question.