
MTS / DTC not rollling back transaction
Quote:
> Niels
> I cannot do that without causing transactions to be started for
> retrieving
> data and validating data
> Dave
> > Dave,
> > What happens if you change MainWrapperClass to RequiresTransaction?
> > Later...
> > Niels
> > >Hi,
> > >I am not able to get MTS to rollback transaction. I am running VB6
> > SP3 /
> > >NT40 SP4 / MTS 2 / SQL Server 6.5.
> > >Here is the scenario:
> > >CreateObject from client MainWrapperClass Supports Transactions
> > > MainWrapperClass Creates Instances of TransactionWrapperClass
> > >Requires Transaction
> > > TransactionWrapperClass Creates Instances of Table Class A
> > >Supports Transactions
> > > TransactionWrapperClass Creates Instances of Table Class B
> > >Supports Transactions
> > >each method called in each class calls SetAbort in the error handler
> > or
> > >setcomplete at the end of the method
> > >When I force Class B to fail (with a timestamp error) the changes to
> Class
> > >A's data are not rolled back.
> > >Any help would be greatly appreciated...
> > >Thanks and please post to group,
> > >Dave
You may need to split the classes into a retreival and an insert/update
with a third class being the manager class that decides where to go.
Then you mark them as follows:-
Manager - Supports Transactions
Updater - Requires Transactons
Reader - No Transactions
Regards
Paul Hatcher, MCSD
Principal Consultant
Graduate Associates Ltd