The expected results afer a swap is: ID 5, Name: Foo, Content "EFG" ID 10, Name: Bar, Content "ABC" This gives you the same ID stability that "open"-> "write"-> "close" would, without the risk of partial contents or file "damage". Side Note: Just to be clear, the modificati...