Safe delete using TSQL