[GRASS-user] how to update one attribute of a small vector map?
Milton Cezar Ribeiro
miltinho.astronauta at gmail.com
Mon May 18 12:23:11 EDT 2009
Sorry to expand a little bit this thread. I have a vector map with 10
thousands of records, and for each record I have a set of about 10
attributes. Now I would like to generate a raster map from one attribute of
vector map. But on vector I have CHAR values like: "Low", "Medium" and
"High", and I would like that my raster map get values 1, 2 and 3,
Any help are welcome.
2009/5/18 Micha Silver <micha at arava.co.il>
> Offenthaler Ivo wrote:
>> What would you suggest as the most convenient way to update a small (60
>> points) vector map? E.g. a map's attribute "pollution_level" for a given
>> point-ID (attribute "sitecode") has to be updated, based on some plain text
>> output (columns "sitecode" and "pollution level") of another software?
> In a command shell, you might find something like this will do it:
> while read sc pl
> echo "UPDATE <vect_point_map> SET pollution_level=$pl WHERE sitecode=$sc"
> | db.execute
> done < plain_text_file
> This assumes that the plain_text_file is just two columns, sitecode and
> pollution_level. You can loop thru the new values any way that's convenient.
> The line:
> echo "UPDATE .... WHERE ..." | db.execute
> is what does the work.
>> Many thanks in advance! Ivo
>> grass-user mailing list
>> grass-user at lists.osgeo.org
>> This mail was received via Mail-SeCure System.
> grass-user mailing list
> grass-user at lists.osgeo.org
-------------- next part --------------
An HTML attachment was scrubbed...
More information about the grass-user