0

I'm trying to use the "Delete duplicates by attribute" tool in QGIS's Graphical Model Builder. My aim is to delete duplicates based on two fields, "Point_ID" and "Agg_Class". I can easily do this using the tool on it's own, but I can't figure out how to get this to work in the model builder.

enter image description here

Babel
79.7k15 gold badges96 silver badges244 bronze badges
asked Jan 22 at 14:15
4
  • The correct syntax is shown when you hover the cursor: imgur.com/a/kz582KH. field1;field2;fieldx Commented Jan 22 at 14:43
  • The expression has to be enclosed in single quotes ' Commented Jan 25 at 9:26
  • 1
    Not when I try it. But there must not be a whitespace between the field names point_id;Agg_Class works, but not point_id; Agg_Class Commented Jan 25 at 10:07
  • Hey! Initially this didn't work either, but after changing the order of the fields it worked on my end. I can't explain it, but thanks a million for the answer! Commented Jan 27 at 9:28

1 Answer 1

2

Use Pre-calculated Value (icon ε) instead of value and enter the fieldnames in either of the following syntaxes : 'Point_ID;Agg_Class' or array('Point_ID','Agg_Class')

Expected fomat: selected field names as an array of names, or semicolon separated string of options (e.g. 'fid;place_name')

enter image description here

answered Jan 22 at 14:41
1
  • 1
    Hey All, this worked for me! Thanks a million for the help! Commented Jan 27 at 9:27

Your Answer

Draft saved
Draft discarded

Sign up or log in

Sign up using Google
Sign up using Email and Password

Post as a guest

Required, but never shown

Post as a guest

Required, but never shown

By clicking "Post Your Answer", you agree to our terms of service and acknowledge you have read our privacy policy.

Start asking to get answers

Find the answer to your question by asking.

Ask question

Explore related questions

See similar questions with these tags.