Bug report #134
After create a postgis layer and filldata, Qgis dont display attributes
|Assignee:||Brendan Morley -|
|Affected QGIS version:||Regression?:||No|
|Operating System:||Windows||Easy fix?:||No|
|Pull Request or Patch supplied:||Resolution:||fixed|
|Crashes QGIS or corrupts data:||Copied to github as #:||10193|
We are beginning to use QGis, however we have some problems that could be errors on your software.
We have the Windows version (0.7.3) and when connect to Postgis, we select the layer (previous created with SQL statement) and edit some points.
After stop editing and save, we leave Qgis and if we enter again on Qgis and ask for that postgis layer, Qgis recognize the database records but it can’t display the information stored on those records, leaving fields blank on attribute table.
Can you help us?
- POSTGIS LAYER:::
CREATE TABLE cli_abm
numregisto int8 NOT NULL,
CONSTRAINT pri_cli_abm PRIMARY KEY (numregisto),
CONSTRAINT enforce_dims_geom CHECK (ndims(geom) = 2),
CONSTRAINT enforce_geotype_geom CHECK (geometrytype(geom) = 'POINT'::text OR geom IS NULL),
CONSTRAINT enforce_srid_geom CHECK (srid(geom) = -1)
ALTER TABLE cli_abm OWNER TO postgres;
#3 Updated by Brendan Morley - about 14 years ago
I think I've worked out the "spirit" of this bug, at least with regards to SVN HEAD.
If the attributes are edited via the attributes table, the changes "take" when saved.
If the attributes are edited via the Identify window, the changes do not take.
I will continue to investigate.
#4 Updated by Brendan Morley - about 14 years ago
The second method fails because when it commits, it tries to commit all attributes of a changed feature instead of just the changed attributes of that changed feature (which is what the "attributes table" method already does).
In particular, the second "Identify window" method tries to set a Postgres Date type to _, which Postgres chokes on and aborts the commit.
A side issue is that the Postgres provider then doesn't report the error, which it should.