On   a fine day , your boss comes to your desk and says that , there are 50k records deleted from the tables, Do you know what happen So?

 The only option you have is to read the transaction log file,if you don’t take transaction backup of your database, then you are left over in the hell.below is the query to read the transaction log file, which gives you complete details about all the operations done on it,

declare @start nvarchar (22)
declare @end nvarchar (22)
declare @filename nvarchar(260)
declare @seqno int
set @start = Null
set @end  = Null
set @filename = 'c:testtest.trn'
set @seqno = 1
select * from sys.fn_dump_dblog (@start, @end, NULL, @seqno, @filename,
In the Result grid you will be seeing LOP_DELETE_ROWS in the operation row,and check the
end time of the transaction, which gives you the complete details

Leave a Reply

Your email address will not be published. Required fields are marked *