title: UPDATE and REPLACE part of a string
body: <p>I've got a table with two columns, <code>ID</code> and <code>Value</code>. I want to change a part of some strings in the second column.</p>
  
  <p>Example of Table:</p>
  
  <pre class="lang-none prettyprint-override"><code>ID            Value
  ---------------------------------
  1             c:\temp\123\abc\111
  2             c:\temp\123\abc\222
  3             c:\temp\123\abc\333
  4             c:\temp\123\abc\444
  </code></pre>
  
  <p>Now the <code>123\</code> in the <code>Value</code> string is not needed. I tried <code>UPDATE</code> and <code>REPLACE</code>:</p>
  
  <pre><code>UPDATE dbo.xxx
  SET Value = REPLACE(Value, '%123%', '')
  WHERE ID &lt;= 4
  </code></pre>
  
  <p>When I execute the script SQL Server does not report an error, but it does not update anything either. Why is that?</p>