Transaction management in db2
Posted on 2003-11-24
I have an application in c#(windows application on ) with DB2 database(that is on AS400). The client interface class uses a dataaccess class to interact with the database. The application runs 3 stored procedures one by one calling the functions of the dataaccess class that inserts the data in 3 tables.
Now the problem is to manage the transaction in all the 3 procedures i.e. if 3rd procedure fails then the execution of previously run 2 procedures should also be rolled back.
I am using "DB2OLEDB" provider. I have the M/S Host Integration server installed. I am using ADO.net transaction object and command object to execute DB2 stored procedures.
Can you please help me to resolve the issue.
Thanks in advance.