Golgappa.net | Golgappa.org | BagIndia.net | BodyIndia.Com | CabIndia.net | CarsBikes.net | CarsBikes.org | CashIndia.net | ConsumerIndia.net | CookingIndia.net | DataIndia.net | DealIndia.net | EmailIndia.net | FirstTablet.com | FirstTourist.com | ForsaleIndia.net | IndiaBody.Com | IndiaCab.net | IndiaCash.net | IndiaModel.net | KidForum.net | OfficeIndia.net | PaysIndia.com | RestaurantIndia.net | RestaurantsIndia.net | SaleForum.net | SellForum.net | SoldIndia.com | StarIndia.net | TomatoCab.com | TomatoCabs.com | TownIndia.com
Interested to Buy Any Domain ? << Click Here >> for more details...

If i have one transaction say mainTransaction, within this
mainTransaction i have another two transaction say t1 and t2.
Now while execution t1 completes successfully and commit
statement fires, but while executing t2 some error occurs
and rollback statement fires.
What happen to t1, is it rollback or not?

Answer Posted / candorz

BEGIN TRANSACTION
GO
BEGIN TRANSACTION
INSERT INTO [JSSKDB].[dbo].[JobsDb_Countries]
([CountryName])
VALUES
('something')
GO
COMMIT
GO
BEGIN TRANSACTION
INSERT INTO [JSSKDB].[dbo].[JobsDb_Countries]
([CountryName])
VALUES
('something1')
ROLLBACK
GO


For the above transaction the rollback will undo any changes made by the previous sub-transaction i.e. no change will be seen in the DB

Is This Answer Correct ?    7 Yes 1 No



Post New Answer       View All Answers


Please Help Members By Posting Answers For Below Questions

Do you know what is fill factor and pad index?

940


What are the basic functions for master, msdb, model, tempdb and resource databases?

937


What is transaction server distributed transaction?

976


What does indexation mean?

916


Explain why variables called the most powerful component of ssis?

989


what purpose does the model database serve? : Sql server database administration

920


what’s the difference between Covering Indexes and Clustered Indexes ? how to use clustered index small ?

1908


Name three of the features managed by the surface area configuration tool? : sql server security

943


How to test odbc dsn connection settings?

966


What are xml indexes?

891


Any one plz send me SQL Server Developer/DBA resume for 4 years experience

2666


What is index, cluster index and nonclustered index?

926


How to create new tables with "select ... Into" statements in ms sql server?

929


How to create indexed view?

985


What are the different types of cursor?

1039