<html><head><meta http-equiv="Content-Type" content="text/html charset=us-ascii"></head><body style="word-wrap: break-word; -webkit-nbsp-mode: space; -webkit-line-break: after-white-space; "><p style="margin: 0px 0px 1em; padding: 0px; border: 0px; font-size: 14px; vertical-align: baseline; clear: both; word-wrap: break-word; color: rgb(51, 51, 51); font-family: 'Helvetica Neue', Helvetica, Arial, sans-serif; line-height: 18px; text-align: left; background-color: rgba(248, 248, 248, 0.589844); position: static; z-index: auto; ">**This question is also posted on <a href="http://stackexchange.com">stackexchange.com</a>**</p><p style="margin: 0px 0px 1em; padding: 0px; border: 0px; font-size: 14px; vertical-align: baseline; clear: both; word-wrap: break-word; color: rgb(51, 51, 51); font-family: 'Helvetica Neue', Helvetica, Arial, sans-serif; line-height: 18px; text-align: left; background-color: rgba(248, 248, 248, 0.589844); position: static; z-index: auto; ">I have a vector map that includes 100 points. These points were created using <code style="margin: 0px; padding: 1px 5px; border: 0px; vertical-align: baseline; font-family: Consolas, Menlo, Monaco, 'Lucida Console', 'Liberation Mono', 'DejaVu Sans Mono', 'Bitstream Vera Sans Mono', 'Courier New', monospace, serif; color: rgb(34, 34, 34); background-color: rgb(238, 238, 238); ">v.extract</code> to randomly sample a larger map of 10k points. As such, the 'cat' values range from 1 to more than 10k. What I would like to do is to update the attribute table by rescaling these values to 1 to 100.</p><p style="margin: 0px 0px 1em; padding: 0px; border: 0px; font-size: 14px; vertical-align: baseline; clear: both; word-wrap: break-word; color: rgb(51, 51, 51); font-family: 'Helvetica Neue', Helvetica, Arial, sans-serif; line-height: 18px; text-align: left; background-color: rgba(248, 248, 248, 0.589844); position: static; z-index: auto; ">Here's what I've experienced. If I use</p><pre class="lang-html prettyprint prettyprinted" style="margin-top: 0px; margin-bottom: 10px; padding: 5px; border: 0px; font-size: 12px; vertical-align: baseline; overflow: auto; width: auto; max-height: 600px; font-family: Consolas, Menlo, Monaco, 'Lucida Console', 'Liberation Mono', 'DejaVu Sans Mono', 'Bitstream Vera Sans Mono', 'Courier New', monospace, serif; background-color: rgb(238, 238, 238); color: rgb(57, 51, 24); line-height: 18px; text-align: left; "><code style="margin: 0px; padding: 0px; border: 0px; vertical-align: baseline; font-family: Consolas, Menlo, Monaco, 'Lucida Console', 'Liberation Mono', 'DejaVu Sans Mono', 'Bitstream Vera Sans Mono', 'Courier New', monospace, serif; color: rgb(34, 34, 34); "><span class="pln" style="margin: 0px; padding: 0px; border: 0px; vertical-align: baseline; color: black; ">v.category input=pts100 output=foo option=del
v.category input=foo output=pts100 option=add --o</span></code></pre><p style="margin: 0px 0px 1em; padding: 0px; border: 0px; font-size: 14px; vertical-align: baseline; clear: both; word-wrap: break-word; color: rgb(51, 51, 51); font-family: 'Helvetica Neue', Helvetica, Arial, sans-serif; line-height: 18px; text-align: left; background-color: rgba(248, 248, 248, 0.589844); ">Then when the 'cat' values <em style="margin: 0px; padding: 0px; border: 0px; vertical-align: baseline; ">appear</em> rescaled when I print them with</p><pre class="lang-html prettyprint prettyprinted" style="margin-top: 0px; margin-bottom: 10px; padding: 5px; border: 0px; font-size: 12px; vertical-align: baseline; overflow: auto; width: auto; max-height: 600px; font-family: Consolas, Menlo, Monaco, 'Lucida Console', 'Liberation Mono', 'DejaVu Sans Mono', 'Bitstream Vera Sans Mono', 'Courier New', monospace, serif; background-color: rgb(238, 238, 238); color: rgb(57, 51, 24); line-height: 18px; text-align: left; "><code style="margin: 0px; padding: 0px; border: 0px; vertical-align: baseline; font-family: Consolas, Menlo, Monaco, 'Lucida Console', 'Liberation Mono', 'DejaVu Sans Mono', 'Bitstream Vera Sans Mono', 'Courier New', monospace, serif; color: rgb(34, 34, 34); "><span class="pln" style="margin: 0px; padding: 0px; border: 0px; vertical-align: baseline; color: black; ">v.category input=pts100 option=print</span></code></pre><p style="margin: 0px 0px 1em; padding: 0px; border: 0px; font-size: 14px; vertical-align: baseline; clear: both; word-wrap: break-word; color: rgb(51, 51, 51); font-family: 'Helvetica Neue', Helvetica, Arial, sans-serif; line-height: 18px; text-align: left; background-color: rgba(248, 248, 248, 0.589844); ">However, if I look at the dbtable with</p><pre class="lang-html prettyprint prettyprinted" style="margin-top: 0px; margin-bottom: 10px; padding: 5px; border: 0px; font-size: 12px; vertical-align: baseline; overflow: auto; width: auto; max-height: 600px; font-family: Consolas, Menlo, Monaco, 'Lucida Console', 'Liberation Mono', 'DejaVu Sans Mono', 'Bitstream Vera Sans Mono', 'Courier New', monospace, serif; background-color: rgb(238, 238, 238); color: rgb(57, 51, 24); line-height: 18px; text-align: left; "><code style="margin: 0px; padding: 0px; border: 0px; vertical-align: baseline; font-family: Consolas, Menlo, Monaco, 'Lucida Console', 'Liberation Mono', 'DejaVu Sans Mono', 'Bitstream Vera Sans Mono', 'Courier New', monospace, serif; color: rgb(34, 34, 34); "><span class="pln" style="margin: 0px; padding: 0px; border: 0px; vertical-align: baseline; color: black; ">db.select pts100</span></code></pre><p style="margin: 0px 0px 1em; padding: 0px; border: 0px; font-size: 14px; vertical-align: baseline; clear: both; word-wrap: break-word; color: rgb(51, 51, 51); font-family: 'Helvetica Neue', Helvetica, Arial, sans-serif; line-height: 18px; text-align: left; background-color: rgba(248, 248, 248, 0.589844); position: static; z-index: auto; ">the 'cat' values have not changed (presumably because it is the key column).</p><p style="margin: 0px 0px 1em; padding: 0px; border: 0px; font-size: 14px; vertical-align: baseline; clear: both; word-wrap: break-word; color: rgb(51, 51, 51); font-family: 'Helvetica Neue', Helvetica, Arial, sans-serif; line-height: 18px; text-align: left; background-color: rgba(248, 248, 248, 0.589844); position: static; z-index: auto; ">So I'm thinking I will need to add a new column using <code style="margin: 0px; padding: 1px 5px; border: 0px; vertical-align: baseline; font-family: Consolas, Menlo, Monaco, 'Lucida Console', 'Liberation Mono', 'DejaVu Sans Mono', 'Bitstream Vera Sans Mono', 'Courier New', monospace, serif; color: rgb(34, 34, 34); background-color: rgb(238, 238, 238); ">v.db.addcol</code>, but I don't know how to specify the range of value to populate the new column. From what I can tell, I have to specify a single value.</p><p style="margin: 0px 0px 1em; padding: 0px; border: 0px; font-size: 14px; vertical-align: baseline; clear: both; word-wrap: break-word; color: rgb(51, 51, 51); font-family: 'Helvetica Neue', Helvetica, Arial, sans-serif; line-height: 18px; text-align: left; background-color: rgba(248, 248, 248, 0.589844); position: static; z-index: auto; ">Ideas?</p></body></html>