Bug report #15197
Error when saving edited layer from Spatialite database
|Affected QGIS version:||master||Regression?:||No|
|Operating System:||OS X||Easy fix?:||No|
|Pull Request or Patch supplied:||No||Resolution:||not reproducable|
|Crashes QGIS or corrupts data:||No||Copied to github as #:||23136|
I use master version QGIS 2.15 6000ff4f and there is very serious error during editing vector layers from Spatialite database. It's impossible to save changes in layers. There is error like that:
Nie można zatwierdzić zmian dla warstwy mala architektura i oznaczenia v6
Błędy: BŁĄD: nie dodano 1 obiektu.
Błędy źródła danych:
Błąd SQLite: tymczas.Geometry violates Geometry constraint [geom-type or SRID not allowed]
SQL: INSERT INTO "mala architektura i oznaczenia v6"("geometry","rodzaj") VALUES (ST_Multi(GeomFromWKB(?, 2180)),?)
Sorry that this is in Polish. Which is strange error occurs only sometimes, without any noticeable patterns or cause, at least for me. Which is strange in the same time I can save edited layer as SHP or CSV without any problem. I can also import this SHP to database without any errors. But it is very time consuming.
#7 Updated by Giovanni Manghi about 5 years ago
- Category set to Data Provider/SpatiaLite
- Priority changed from High to Normal
- Crashes QGIS or corrupts data changed from Yes to No
Could you please attach sample data? Thanks!
it seems to me there is no data corruption, the original data is not lost or changed in any form, the issue is just about saving new data.
#8 Updated by Giovanni Manghi over 4 years ago
Reinhard Reiterer wrote:
Just create a new SpatiaLite table (Geometry: LineString) and add crossing line features. Next, select the features and merge them. Saving the layer edits fails with a similar error like posted above.
if the layer is declared as "lines" (and not "multilines") then is normal that trying create a multigeometry will fail.