fixed database dependency problems