before clean of db