How to Preview or Rollback Your Database Changes Using Transactions on SQL Server!

Published: 30 May 2024
on channel: Tech Tips
24
0

How to preview or rollback your database changes using transactions on SQL Server!

Script used in video:

BEGIN TRAN

INSERT INTO NewTable (Name, Age)
VALUES
('Alice', 25),
('Bob', 35);

DELETE FROM NewTable WHERE ID = 1;

UPDATE NewTable SET Age = 40 WHERE Name = 'Alice';

ROLLBACK TRAN

Drop a like if you found this video helpful!


Watch video How to Preview or Rollback Your Database Changes Using Transactions on SQL Server! online without registration, duration hours minute second in high quality. This video was added by user Tech Tips 30 May 2024, don't forget to share it with your friends and acquaintances, it has been viewed on our site 24 once and liked it 0 people.