fixed small database error