title: add row number based on given column value SQL
body: <p>I would like to add numbers to my rows based on the product value:</p>
  
  <p>Lets say Ive got table:</p>
  
  <pre><code>ProductId Value
  001 10
  002 30
  003 20
  </code></pre>
  
  <p>then when I order it by Value asc I would get:</p>
  
  <pre><code>ProductId Value
  001 10
  003 20
  004 30
  </code></pre>
  
  <p>Now I want to add new column called Position and the result would be like this:</p>
  
  <pre><code>ProductId Value Position
  001 10 1
  002 30 3
  003 20 2
  </code></pre>
  
  <p>Thanks for any help how can I do this.</p>
  
  <p>My database serrver is sql server 2008R2</p>