The problem is how to process transaction logs. He should write for both, but you must process it in pieces.
So ... Try something like this:
While exists (select * from db1.dbo.tablename)
Begin
Delete top 100 from db1.dbo.tablename
Output deleted.* into dbo.tablename;
Checkpoint;
End
source
share