Avatar of robaherne
robaherne

asked on 

How to perform transaction isolation and rollback when using DataAdapters

I want to carry out a number of DataAdapter transactions when creating a new account but I want it to 'rollback' if one transaction doesn't suceed e.g...

try{
Membership.CreateUser(txt_Name.Text, txt_Password.Text,txt_Email.Text);
BandAdapter.Insert(BandId,txt_Bandname.Text, txt_Description.Text);
MembersAdapter.Insert(MemId, BandId, txt_Mem_Name1.Text);
}
catch
{
Rollback;
}

Many thanks.
.NET ProgrammingMicrosoft SQL ServerASP.NET

Avatar of undefined
Last Comment
robaherne
ASKER CERTIFIED SOLUTION
Avatar of Jeeva Subburaj
Jeeva Subburaj
Flag of United States of America image

Blurred text
THIS SOLUTION IS ONLY AVAILABLE TO MEMBERS.
View this solution by signing up for a free trial.
Members can start a 7-Day free trial and enjoy unlimited access to the platform.
See Pricing Options
Start Free Trial
Avatar of robaherne
robaherne

ASKER

Thanks!
Microsoft SQL Server
Microsoft SQL Server

Microsoft SQL Server is a suite of relational database management system (RDBMS) products providing multi-user database access functionality.SQL Server is available in multiple versions, typically identified by release year, and versions are subdivided into editions to distinguish between product functionality. Component services include integration (SSIS), reporting (SSRS), analysis (SSAS), data quality, master data, T-SQL and performance tuning.

171K
Questions
--
Followers
--
Top Experts
Get a personalized solution from industry experts
Ask the experts
Read over 600 more reviews

TRUSTED BY

IBM logoIntel logoMicrosoft logoUbisoft logoSAP logo
Qualcomm logoCitrix Systems logoWorkday logoErnst & Young logo
High performer badgeUsers love us badge
LinkedIn logoFacebook logoX logoInstagram logoTikTok logoYouTube logo