Entity Framework - Using Transactions or SaveChanges(false) and AcceptAllChanges()?
- by mark smith
Hi there,
I have been investigating transactions and it appears that they take call of them selves in EF as long as i pass false to savechanges..
SaveChanges(false)
and if all goes well then AcceptAllChanges()
Question is what is something goes bad, don't have to rollback? or as soon as the my method goes out of scope its ended?
What happens to any indentiy columns that were assigned half way through the transaction.. i presume if somebody else added a record after mine before mine went bad then this means there will be a missing Identity value.
Is there any reason to use standard "transactionScope" in code?
ideas? - thanks