title: Updating Field in RavenDB Document
body: <p>Good day,</p>
  
  <p>I have a RavenDB JSON Document in which one field ("Info") contains a string that looks like this:</p>
  
  <pre><code>"{\"value1\":\"9\", \"value2\": \"dog\", ....}"
  </code></pre>
  
  <p>I would like to remove the escaping <code>"\"</code> characters so it will be recognized as a JSON List by RavenDB. </p>
  
  <p>However, I have tried updating the Documents with </p>
  
  <p><code>newString = oldString.Replace("\\", "")</code> , </p>
  
  <p><code>newString = oldString.Replace(@"\", "")</code> </p>
  
  <p>and <code>newString = oldString.Trim(new Char[] { @"\" })</code></p>
  
  <p>but it does not work. After applying these above mentioned methods the string looks unchanged.</p>
  
  <p>Please see below the full code:</p>
  
  <pre><code>            while(true)
              {
                  var result = session.Query&lt;Documents&gt;()
                      .Take(1000).Skip(i)
                      .ToList();
                  if (result.Count == 0)
                      break;
  
                  foreach (var r in result)
                  {
                      string rInfo = r.Info.ToString();
                      rInfo = rInfo.Replace("\\", "");
  
                      PATCHED_Doc r_Doc = new PATCHED_Doc()
                      {
                          Info = rInfo, 
                          Value = "test",
                          Id = r.Id,
                          Date = r.Date,
                      };
  
                      session.Store(r_Doc);
                      session.SaveChanges();
  
                  }
  
                  session.SaveChanges();
  
                  i += result.Count;
              }
  
  
  
  public class PATCHED_Doc
  {
      public string Info { get; set; }
      public string Value { get; set; }
      public int Id { get; set; }
      public string Date { get; set; }
  }
  </code></pre>
  
  <p>Thank you in advance for helping.</p>