fixed database fragment bug