bug fix database allocation limit