Click here to hide categories Click here to show left categories

User: Home          welcome : Guest          Log In / Register here     




Can i Rollback the Table DataTypes while using Transactions in sql server?

Table data types are unaffected by rollback statements when using transactions.


Example:

begin transaction
declare @emp  table (empid int)
insert into @emp values(10);
insert into @emp values(20);
rollback

select * from @emp
--------------------------------
10
20

even though you rollback the data table variables will persist the data.

Share this article   |    Print    |    Article read by 3209 times
Author:
rajeev chandra
hi this is rajeev
Related Articles:
Related Interview Questions: