title: Return ID on INSERT?
body: <p>I have an INSERT query and I want the DB to return the ID of the row I just inserted.</p>
  
  <pre><code>sqlString = "INSERT INTO MagicBoxes (OwnerID, Key, Name, Permissions, Active, LastUpdated) VALUES (@OwnerID, @BoxKey, @BoxName, 0, 1, @Date) SET @ID = SCOPE_IDENTITY();";
  cmd = new SqlCommand(sqlString, con);
  cmd.Parameters.AddWithValue("@OwnerID", OwnerID);
  cmd.Parameters.AddWithValue("@BoxKey", BoxKey);
  cmd.Parameters.AddWithValue("@BoxName", BoxName);
  cmd.Parameters.AddWithValue("@Username", Username);
  cmd.Parameters.AddWithValue("@Date", DateTime.Now);
  cmd.ExecuteNonQuery();
  </code></pre>
  
  <p>I currently have this, I'm not sure what I need to do next...</p>