title: How can I update a field in a MySQL database table by addition in MySQL database in a single query
body: <p>I have a table that stores a value that will be added to over time. When I want to add to the value I would like to do so in a single query rather than -</p>
  
  <ol>
  <li>Get oldValue from database</li>
  <li>newValue = oldValue + X</li>
  <li><p>update row with newValue</p>
  
  <p>$query1 = "SELECT value FROM table WHERE id = thisID";
  $result1 = mysql_query($query1);
  while($row=mysql_fetch_array($result)) {
    $oldValue = $row['value'];
  }
  $newValue = $oldValue + x
  $query1 = "UPDATE table SET value = $newValue WHERE id = thisID";</p></li>
  </ol>
  
  <p>Can this be done in a single query?</p>