thanks for your attention, time and sharing.
I am using DAAB 4.0 with C# and SQL Server 2005. Please guide me how I can manage Transactions using DAAB when adding data in multiple tables ? I am using DAAB in the following way:
public int SaveProductDetails(string Parameter1, string Parameter2)
object objresult = db.ExecuteNonQuery("p_save_product", Parameter1,Parameter2);
result = Int32.Parse(objresult.ToString());
You would make use of TransactionScope class. Make sure that you use the same instance of a TransactionScope object for those operations
that you would want to include in the transaction. Here's a related
You could also make use of the overloads of ExecuteNonQuery that accepts a DbTransaction object. Create a DbConnection object from your Database object and then make use of that connection object to create a DbTransaction object. Again, you need
to make use of a single instance of a DbTransaction object and call against it either Commit or Rollback.
Global Technology and Solutions