qgis / QGIS

QGIS is a free, open source, cross platform (lin/win/mac) geographical information system (GIS)
https://qgis.org
GNU General Public License v2.0
10.39k stars 2.98k forks source link

Attributes Form Editor - Can't set form to enforce INSERT not UPDATE #33069

Open Saijin-Naib opened 4 years ago

Saijin-Naib commented 4 years ago

Describe the bug There does not appear to be a way to force the input from an Attributes Form entry to be an INSERT operation, thus writing a new line to the database as opposed to an UPDATE operation, changing values that exist already and INSERTING only when no prior values exist.

How to Reproduce Setup an Attributes Form that can be used to take repeat measurements of an item.

Change a value(s) to indicate it is a repeated survey, go to write the data, and the data is UPDATED not INSERTED. Instead of two discrete entries, you still have the one with the latest change. QGIS and OS versions

QGIS version 3.10.0-A Coruña QGIS code revision 6ffa89eb3e
Compiled against Qt 5.11.2 Running against Qt 5.11.2
Compiled against GDAL/OGR 3.0.2 Running against GDAL/OGR 3.0.2
Compiled against GEOS 3.8.0-CAPI-1.13.1 Running against GEOS 3.8.0-CAPI-1.13.1
Compiled against SQLite 3.29.0 Running against SQLite 3.29.0
PostgreSQL Client Version 11.5 SpatiaLite Version 4.3.0
QWT Version 6.1.3 QScintilla2 Version 2.10.8
Compiled against PROJ 6.2.1 Running against PROJ Rel. 6.2.1, November 1st, 2019
OS Version Windows 10 (10.0)
Active python plugins CalculateGeometry; cartogram3; changeDataSource; DataPlotly; DEMto3D; dzetsaka; GeoCoding; GeodesicDensifier; geomovetools; getools; GroupPointsWithinDistance; guided_offline_editing; htpgeoprocessor; joinmultiplelines; karika; kmltools; kml_style_importer; LandSurveyCodesImport; LAStools; latlontools; LineDirectionHistogram; lrs; maps2winbugs; MemoryLayerSaver; minimum_spanning_tree; mmqgis; networks; openlayers_plugin; oscars-georaster-qgis-plugin; ParallelLineConstruction; pdaltools; photo2shape; PluginLoadTimes; Polygons_Pile; polystrip; processing_circuitscape; processing_fusion; processing_gnm; processing_js; processing_pktools; processing_prepair; processing_r; processing_saga_nextgen; processing_taudem; processing_trajectory; processing_whitebox; project_colors_dock; qchainage; qconsolidate; qdraw; qgiscloud; QGISSortAndNumber-master; QRectangleCreator; QuickOSM; realcentroid; refFunctions; SelectWithin; sen2cor_adapter; Serval; shapetools; snail; spatial_query_with_values; SplitPolygonShowingAreas; SpreadsheetLayers; statist; ThToolBox; toggle_labels_widget; trail_elevation_stats; wnt; db_manager; processing

Additional context Related to Issue #33068

gioman commented 4 years ago

Setup an Attributes Form that can be used to take repeat measurements of an item.

Change a value(s) to indicate it is a repeated survey, go to write the data, and the data is UPDATED not INSERTED. Instead of two discrete entries, you still have the one with the latest change.

Related to Issue #33068

Yes is related, and again this is at best a feature request in my opinion.