fixed database rollback