3

I want to reclassify a polygon vector and use v.reclass.

Feature type: boundary

Name of column: LBA

Reclass Rule: I use a .txt with the following content:

CASE
WHEN  LBA  = 68 THEN 2
WHEN  LBA  = 69 THEN 1
ELSE NULL
END

There is no result and no error message...

1 Answer 1

1

As far as I know, the code you typed is not suitable for v.reclass but for Field calculator in QGIS. In any case, you should add double quotes and single quotes to your code:

  • double quotes for column names: "LBA"
  • single quotes for values if they are in a varchar columns: '68'
  • if the LBA column or the column that will save your reclassified values is an integer/real/double columns, single quotes are not necessary.

    CASE
      WHEN "LBA" = 68 THEN 2
      WHEN "LBA" = 69 THEN 1
      ELSE NULL
    END
    

Your Answer

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

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