Bug report #20347

Copy and Move Feature do not respect postgres-provider default values

Added by Jan Lippmann over 5 years ago. Updated over 5 years ago.

Status:Closed
Priority:Normal
Assignee:-
Category:Digitising
Affected QGIS version:3.5(master) Regression?:No
Operating System:Win 7 64bit Easy fix?:No
Pull Request or Patch supplied:No Resolution:
Crashes QGIS or corrupts data:No Copied to github as #:28168

Description

Important: it happens only when "evaluate default values on provider side" is activated in the project settings

definition of gid:

gid integer NOT NULL DEFAULT nextval('dbg_admin_10409.sq_gis_gruen_f_gid'::regclass),
ALTER TABLE dbg_admin_10409.gis_gruen_f ADD CONSTRAINT pk_gis_gruen_f PRIMARY KEY(gid);
CREATE SEQUENCE dbg_admin_10409.sq_gis_gruen_f_gid
INCREMENT 1
MINVALUE 1
MAXVALUE 9223372036854775807
START 35507
CACHE 1;

occur in actual master and 3.4

move_and_paste.gif (2.04 MB) Jan Lippmann, 2018-11-03 11:12 AM

Associated revisions

Revision 4ac06317
Added by David Signer over 5 years ago

createFeature on move and copy

using of the createFeature function with tool move and copy and there the logic of unique not null fields (like primary keys) is used.

This would fix #20347

Revision 672b994e
Added by David Signer over 5 years ago

createFeature on move and copy

using of the createFeature function with tool move and copy and there the logic of unique not null fields (like primary keys) is used.

This would fix #20347

(cherry-picked from 4ac063177460c7dbd8223f19a8b6279711d7bb8d)

History

#1 Updated by Giovanni Manghi over 5 years ago

  • Category changed from Data Provider/PostGIS to Digitising
  • Status changed from Open to Feedback

why regression? did it worked as expected in a previous version?

#2 Updated by Jan Lippmann over 5 years ago

sorry i think its no regression compared with 3.2.3. i have tested no other versions.
it did not work with 3.2.3 too.

#3 Updated by Giovanni Manghi over 5 years ago

  • Status changed from Feedback to Open
  • Regression? changed from Yes to No
  • Priority changed from High to Normal

#4 Updated by David Signer over 5 years ago

  • % Done changed from 0 to 100
  • Status changed from Open to Closed

Also available in: Atom PDF