I'm trying to make a selection by attribute with python on QGIS Essen, but it looks like I am making a mistake on the script and I can not find it. Can somebody tell me what I have made wrong, or how can I select attributes without using the select by attribute algorithm?

This is my script:


And this is the error:

Error: Wrong number of parameters

ALGORITHM: Select by attribute

    INPUT <ParameterVector>
    FIELD <parameters from INPUT>
    OPERATOR <ParameterSelection>
    VALUE <ParameterString>
    OUTPUT <OutputVector>


    0 - =
    1 - !=
    2 - >
    3 - >=
    4 - <
    5 - <=
    6 - begins with 
    7 - contains

I think the confusion lies with the OUTPUT parameter where the algorithm does not require this as you're only selecting attributes from the same layer. Remove this from your algorithm (this should also be removed from the documentation in my opinion).

So your algorithm should look like:


Actually ignore this - I misinterpreted the question.

  • What was the bug you mentioned? Was it related to "Unsupported field type "Integer64"? – Joseph Apr 28 '16 at 9:16

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.