Bug report #17261
Value relation widget update incorrectly tries to use value instead of key
Status: | Closed | ||
---|---|---|---|
Priority: | Normal | ||
Assignee: | Matthias Kuhn | ||
Category: | Relations | ||
Affected QGIS version: | master | Regression?: | No |
Operating System: | MacOS | Easy fix?: | No |
Pull Request or Patch supplied: | No | Resolution: | |
Crashes QGIS or corrupts data: | No | Copied to github as #: | 25159 |
Description
I am having a problem using the value relation widget in QGIS 2.99999 / master. Here is my simple scenario:
The intention is to show the trail_section table (which has a geometry column) and include in it various properties from the trail table (for line colour and so on). I set up my relations like this:
The table form view shows the trail name instead of the trail_id nicely but whenever I click on a record, the label turns red and I get the following error whenever I try to commit:
From the error message I can see that it is trying to update the trail_section.trail_id with the value of the trail relation rather than the key.
Associated revisions
History
#1 Updated by Giovanni Manghi about 7 years ago
- Status changed from Open to Feedback
Works as expected on QGIS LTR?
#2 Updated by Tim Sutton about 7 years ago
Hi Giovanni. Yes I tested and the same procedure seems to work in 2.18 but not in QGIS 3. I will go and triple check that I followed the same workflow and report back here if it was my fault :-P
#3 Updated by Giovanni Manghi about 7 years ago
- Status changed from Feedback to Open
#4 Updated by Anonymous about 7 years ago
- % Done changed from 0 to 100
- Status changed from Open to Closed
Applied in changeset qgis|032ca68ba3834d16ba34eff27e104d7fb1c6945f.