Bug report #9145
Range Edit Widget not Selectable for Spatialite Layers.
|Affected QGIS version:||2.0.1||Regression?:||No|
|Operating System:||Easy fix?:||No|
|Pull Request or Patch supplied:||No||Resolution:|
|Crashes QGIS or corrupts data:||No||Copied to github as #:||17780|
Unable to select the Range edit widget for spatialite layers. I've tried with int, small int, and real datatypes and in all cases the dialog is unselectable and states "Attribute has not integer or real attribute type". The range edit widget is selectable for an int field when using a shapefile.
I tested this on:
OS X 10.7.5
This is repeatable by creating a spatialite layer with an integer or float datatype and setting the edit widget to Range in the layer properties for the field.
QGIS version 2.0.1-Dufour QGIS code revision f738351
Compiled against Qt 4.8.5 Running against Qt 4.8.5
Compiled against GDAL/OGR 1.10.1 Running against GDAL/OGR 1.10.1
Compiled against GEOS 3.4.2-CAPI-1.8.2 Running against GEOS 3.4.2-CAPI-1.8.2 r3921
PostgreSQL Client Version 9.2.4 SpatiaLite Version 4.1.1
QWT Version 6.0.2 PROJ.4 Version 480
QScintilla2 Version 2.7.2
#1 Updated by Torsten Ernst over 6 years ago
There is some other odd behavior I found when exploring this a bit more:
1. DB Manager recognizes the integer field as int, but the field properties at times only recognizes the primary key field as int, while all others are interpreted as text. Sometimes the field properties do interpret the datatypes correctly, but this does not affect whether or not the Range widget can be selected.
2. In one case, by removing the layer and re-adding it I was able to select the Range widget but the spinner was greyed out in the feature edit dialog (during an edit session).
3. When using a QT UI file, the spinner displays and operates correctly, but the data is not saved to layer after edits are saved.