Delete logic foreign key constraint problem solved