Transactions in Etntity framework
I need some idea in handling transactions in Entity framework.

Lets consider a small example.

In my DB i have a table A with auto generated identity column id, and i have a table B with a reference key to A(id).

In a scenario where i need to insert data in to both tables A and B, i want to start a transaction. Lets a new row is inserted into A , i need newly inserted idnetity(id) value this i need to utilize for B record insertion.

can some one give me lead of handling this situation. Do we need to really utilize transactions in this case?



Transactions in Etntity framework
===

I need some idea in handling transactions in Entity framework.

Lets consider a small example.

In my DB i have a table A with auto generated identity column id, and i have a table B with a reference key to A(id).

In a scenario where i need to insert data in to both tables A and B, i want to start a transaction. Lets a new row is inserted into A , i need newly inserted idnetity(id) value this i need to utilize for B record insertion.

can some one give me lead of handling this situation. Do we need to really utilize transactions in this case?


