Bug report #16760
Relation reference widget: entries with a primary key of 0 initially display as a violation of the NOT NULL constraints
Status: | Closed | ||
---|---|---|---|
Priority: | High | ||
Assignee: | - | ||
Category: | Edit widget | ||
Affected QGIS version: | master | Regression?: | No |
Operating System: | Easy fix?: | No | |
Pull Request or Patch supplied: | No | Resolution: | |
Crashes QGIS or corrupts data: | No | Copied to github as #: | 24659 |
Description
This concerns master (3.x):
Steps to reproduce:
1.
Load any layer (layer A) that allows setting up a relation reference widget with another non-geometry layer
2.
Load a second non-geometry layer (layer B) that has a primary key with integers and starts with zero
3.
Make sure that the initial value before the form opens in layer A and the field of the relation reference widget is set to 0
4.
Open the form of layer A - the form displays a violation of the NOT NULL constraint
5.
Oddly, if one changes to a different value other than 0 and then back to 0, the violation of the NOT NULL constraint is gone
Associated revisions
Fix NULL vs 0 issue in relation reference widget
History
#1 Updated by Anonymous about 7 years ago
- % Done changed from 0 to 100
- Status changed from Open to Closed
Applied in changeset qgis|d299c687d54a19a97512acf3953a9a697c8acdd5.