delete
Declare @I int
Set @I=0
While 1=1
BEGIN
if exists (Select top 1 * from SF_M1_CheckOK
where TransDateTime < '20080101000000')
BEGIN
Delete top (100) from SF_M1_CheckOK
where TransDateTime < '20080101000000'
Set @I=@I+1
print Convert(varchar,@I)
END
ELSe
BEGIN
Break
END
END