title: Linq to SQL - Update object without selecting it first
body: <p>I am playing with ASP.NET MVC3 Beta 2 and am using Linq to SQL for the Model. I one of my controllers, I have an action like so:</p>
  
  <pre><code>    UserDataContext db = new UserDataContext();
      [HttpPost]
      public ViewResult Edit(User um) {
          if (!TryUpdateModel(um)) {
              ViewBag.UpdateError = "Update Failure";
              return View("Details", um);
          }
          //How do I update the existing user? The following fails
          //db.Users.Attach(um, true);
          db.SubmitChanges();
          return View("Details", um); 
      }
  </code></pre>
  
  <p>The User object has fields for Id, FirstName, LastName etc. Is there a way update the existing object (matching by id) without first selecting it, then manually reassigning all the fields?</p>