So I'm trying to rasterize a vector layer by using an attribute filed stored as string, I got the confirmation through the GDAL mailinglist serv that gdal_rasterize does not work with string field. So my question is: is there an easy way to create an ID column based on a existing string column? Basically that would something like this:
"Forest and Woodland" ----- 1"Shrubland and Grassland"---2...and so on
I only have 7 district strings so I suppose I could write some basic python ifloop on the field calculator but what if this value was greater?
Does anyone has some tricky or tip in a situation like this? I'm using QGIS 2.8 and latest GDAL.
Cheers,
أكثر...
"Forest and Woodland" ----- 1"Shrubland and Grassland"---2...and so on
I only have 7 district strings so I suppose I could write some basic python ifloop on the field calculator but what if this value was greater?
Does anyone has some tricky or tip in a situation like this? I'm using QGIS 2.8 and latest GDAL.
Cheers,
أكثر...