I have a child table (depuratori) with a foreign key to a parent table (reti). The parent table has a primary key and two foreign key, no other fields. I have setup the form widget to "Relation Reference".

My problem is that in the "Display expression" of the Relation Reference I can select only the foreign keys of the parent table that are not "human readable". Is there a function (like represent_value() for the Value Map) that retrieve and display the foreign keys of the parent?

  • 2
    Can you provide some screenshots? Because right now I can't figure out what you're trying to do in which dialogue.
    – Erik
    Jul 12, 2021 at 16:49
  • If I understand when you consult "depuratori" you would see value of "reti" and not the key. In this case you must go to layer properties of depuratori, in attributes form. Choose you foreign key for reti, in widget type choose "value relation" in layer : "reti", in key column : column of reti key, in value column ; the value of reti that you would see.
    – vidarusny
    Jul 15, 2021 at 10:10

1 Answer 1


If relation is defined in relation tab of project / properties. enter image description here

You can parameter your table to see the field of link table. In properties of your table, go to attibutes form, in widget type of attributes form tab, choose relation reference. in display name choose the field you want to see. enter image description here

Warning: it is important to declare the link in the right direction for it to be detected. In your example in referenced layer you must have reti / id and in referencing layer depuratori / reti id.

Your Answer

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

Not the answer you're looking for? Browse other questions tagged or ask your own question.