Take the 2-minute tour ×
Geographic Information Systems Stack Exchange is a question and answer site for cartographers, geographers and GIS professionals. It's 100% free, no registration required.

For a shapefile, I have a field named id with the following contents in it:

1
1
2
2

I want to make these values unique such as:

1
2
3
4

Is there any way to achieve this in Quantum GIS (using any plugin or other means) ?

share|improve this question

1 Answer 1

up vote 5 down vote accepted

You can use the Field Calculator in the Attribute table to assign the features unique values by checking "Update existing field", selecting the appropriate field, and entering $rownum in the Expression box. This will assign each feature its row number as its ID.

share|improve this answer

Your Answer

 
discard

By posting your answer, you agree to the privacy policy and terms of service.

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